我在全新的ubuntu安装上设置plex请求服务器(https://github.com/lokenx/plexrequests-meteor/blob/master/README.md)。
我开始下载似乎没有任何问题的流星curl https://install.meteor.com/ | sh
。然后我克隆了plex-requests项目,并从该目录中运行meteor
。
这是生成的错误:
plex@johnpc:/home/plex/plexrequests-meteor$ meteor
[[[[[ /home/plex/plexrequests-meteor ]]]]]
=> Started proxy.
=> Started MongoDB.
Unexpected mongo exit code null. Restarting.
/var/lib/plexmediaserver/.meteor/packages/meteor-tool/.1.1.10.ki0ccv++os.linux.x86_64+web.browser+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/fibers/future.js:245
throw(ex);
^
Error: spawn ENOMEM
at errnoException (child_process.js:1011:11)
at ChildProcess.spawn (child_process.js:958:11)
at Object.exports.spawn (child_process.js:746:9)
at spawnMongod (/var/lib/plexmediaserver/.meteor/packages/meteor-tool/.1.1.10.ki0ccv++os.linux.x86_64+web.browser+web.cordova/mt-os.linux.x86_64/tools/runners/run-mongo.js:39:24)
at launchOneMongoAndWaitForReadyForInitiate (/var/lib/plexmediaserver/.meteor/packages/meteor-tool/.1.1.10.ki0ccv++os.linux.x86_64+web.browser+web.cordova/mt-os.linux.x86_64/tools/runners/run-mongo.js:426:12)
at launchMongo (/var/lib/plexmediaserver/.meteor/packages/meteor-tool/.1.1.10.ki0ccv++os.linux.x86_64+web.browser+web.cordova/mt-os.linux.x86_64/tools/runners/run-mongo.js:610:7)
at [object Object]._.extend._startOrRestart (/var/lib/plexmediaserver/.meteor/packages/meteor-tool/.1.1.10.ki0ccv++os.linux.x86_64+web.browser+web.cordova/mt-os.linux.x86_64/tools/runners/run-mongo.js:704:19)
at [object Object].<anonymous> (/var/lib/plexmediaserver/.meteor/packages/meteor-tool/.1.1.10.ki0ccv++os.linux.x86_64+web.browser+web.cordova/mt-os.linux.x86_64/tools/runners/run-mongo.js:762:14)
at runWithEnvironment (/var/lib/plexmediaserver/.meteor/packages/meteor-tool/.1.1.10.ki0ccv++os.linux.x86_64+web.browser+web.cordova/mt-os.linux.x86_64/tools/utils/fiber-helpers.js:143:21)
我想知道是否还有其他一些我缺少的依赖项,或者还有什么可能导致此问题。我的猜测是它可能是某种权限问题,因为我遇到过这个服务器上的少数几个,但我不知道在哪里。看起来好像在抛出错误的目录上权限是正确的。
plex@johnpc:/home/plex/plexrequests-meteor$ ls -al /var/lib/plexmediaserver
total 40
drwxr-xr-x 8 plex plex 4096 Nov 29 17:31 .
drwxr-xr-x 45 root root 4096 Nov 29 19:28 ..
drwx------ 2 plex plex 4096 Nov 28 22:33 .cache
drwxrwxr-x 3 plex plex 4096 Nov 29 17:10 .cordova
drwxrwxr-x 3 plex plex 4096 Nov 28 21:26 Library
drwxr-xr-x 4 plex plex 4096 Oct 26 20:16 .meteor
-rw------- 1 plex plex 90 Nov 29 17:31 .meteorsession
drwxrwxr-x 11 plex plex 4096 Nov 29 17:31 .npm
drwxrwxr-x 3 plex plex 4096 Nov 29 19:34 .s3ql
-rw------- 1 plex plex 638 Nov 29 17:17 .viminfo
另一个问题是我可能缺少依赖项 - 我安装了mongo以查看是否可以解决问题,但它似乎仍然存在。我尝试了建议here的解决方案,通过设置lang env变量并重置流星,没有任何解决问题的方法。想法?
下面显示的系统在我的macbook pro上完美运行,但是一旦我尝试在我的新ubuntu(Ubuntu 14.04 x64)盒子上重新创建它,就会出现这个问题。
另一种可能性是这可能与记忆有关。当内存耗尽时,我发现人们在网上与流星斗争。它似乎不会发生在我身上,但如果我对此错了,请纠正我。
自由:
/home/plex/plexrequests-meteor master 83s
# ❯ free -m
total used free shared buffers cached
Mem: 490 225 264 0 7 50
-/+ buffers/cache: 168 322
Swap: 0 0 0
的/ proc / meminfo中:
# ❯ cat /proc/meminfo
MemTotal: 501800 kB
MemFree: 269708 kB
Buffers: 8004 kB
Cached: 51856 kB
SwapCached: 0 kB
Active: 147216 kB
Inactive: 48484 kB
Active(anon): 135940 kB
Inactive(anon): 260 kB
Active(file): 11276 kB
Inactive(file): 48224 kB
Unevictable: 0 kB
Mlocked: 0 kB
SwapTotal: 0 kB
SwapFree: 0 kB
Dirty: 0 kB
Writeback: 0 kB
AnonPages: 135880 kB
Mapped: 13188 kB
Shmem: 348 kB
Slab: 18584 kB
SReclaimable: 9436 kB
SUnreclaim: 9148 kB
KernelStack: 1208 kB
PageTables: 5264 kB
NFS_Unstable: 0 kB
Bounce: 0 kB
WritebackTmp: 0 kB
CommitLimit: 250900 kB
Committed_AS: 876812 kB
VmallocTotal: 34359738367 kB
VmallocUsed: 7892 kB
VmallocChunk: 34359722172 kB
HardwareCorrupted: 0 kB
AnonHugePages: 0 kB
HugePages_Total: 0
HugePages_Free: 0
HugePages_Rsvd: 0
HugePages_Surp: 0
Hugepagesize: 2048 kB
DirectMap4k: 32760 kB
DirectMap2M: 491520 kB
DirectMap1G: 0 kB
答案 0 :(得分:2)
根据我对拥有768MB内存的cloud9的经验,在流星运行几分钟并且内存已满后,我会得到同样的异常。
如果你想用流星进行开发,你需要的内存比现有的多得多。如果你只是想运行它,你可以构建应用程序并将其作为一个简单的节点应用程序运行,但MongoDB没有这个,你需要添加额外的。