Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Centos服务器上打包 直接 killed #13

Closed
LuBangTao opened this issue Jun 10, 2020 · 4 comments
Closed

Centos服务器上打包 直接 killed #13

LuBangTao opened this issue Jun 10, 2020 · 4 comments

Comments

@LuBangTao
Copy link

LuBangTao commented Jun 10, 2020

我在Centos服务器上把项目拉下来,vuepress/vuepress-theme-antdocs都安装了,执行vuepress build dosc
image

[root@lannis book2.0]# vuepress build docs
wait Extracting site metadata...
tip Apply theme vuepress-theme-antdocs ...
tip Apply plugin container (i.e. "vuepress-plugin-container") ...
tip Apply plugin @vuepress/last-updated (i.e. "@vuepress/plugin-last-updated") ...
tip Apply plugin @vuepress/register-components (i.e. "@vuepress/plugin-register-components") ...
tip Apply plugin @vuepress/nprogress (i.e. "@vuepress/plugin-nprogress") ...
tip Apply plugin @vuepress/medium-zoom (i.e. "@vuepress/plugin-medium-zoom") ...
tip Apply plugin @vuepress/back-to-top (i.e. "@vuepress/plugin-back-to-top") ...
tip Apply plugin @vuepress/active-header-links (i.e. "@vuepress/plugin-active-header-links") ...
tip Apply plugin @vuepress/search (i.e. "@vuepress/plugin-search") ...

● Client █████████████████████████ building (69%) 715/716 modules 1 active
 css-loader › postcss-loader › less-loader › node_modules/[email protected]@vuepress-theme-antdocs/styles/index.less

● Server █████████████████████████ building (69%) 708/709 modules 1 active
 css-loader › postcss-loader › less-loader › node_modules/[email protected]@vuepress-theme-antdocs/styles/index.less

Killed
[root@lannis book2.0]#

我在centos上用vuepress-creator创建的项目也不能打包~~~vuepress本地也安装了,打包还是失败。。。

image

[root@lannis myproject]# npm run build

> [email protected] build /lannis/opt/myproject
> vuepress build docs

wait Extracting site metadata...
tip Apply theme vuepress-theme-antdocs ...
tip Apply plugin container (i.e. "vuepress-plugin-container") ...
tip Apply plugin @vuepress/last-updated (i.e. "@vuepress/plugin-last-updated") ...
tip Apply plugin @vuepress/register-components (i.e. "@vuepress/plugin-register-components") ...
tip Apply plugin @vuepress/active-header-links (i.e. "@vuepress/plugin-active-header-links") ...
tip Apply plugin @vuepress/search (i.e. "@vuepress/plugin-search") ...
tip Apply plugin @vuepress/nprogress (i.e. "@vuepress/plugin-nprogress") ...
tip Apply plugin smooth-scroll (i.e. "vuepress-plugin-smooth-scroll") ...

● Client █████████████████████████ building (69%) 625/627 modules 2 active
 node_modules/ant-design-vue/es/_util/requestAnimationTimeout.js

● Server █████████████████████████ building (69%) 590/592 modules 2 active
 node_modules/ant-design-vue/es/time-picker/locale/en_US.js

Killed
[root@lannis myproject]#

咋搞哦。、、

@zpfz
Copy link
Owner

zpfz commented Jun 10, 2020

你可以先用 vuepress-creator 创建 Default (默认)主题,然后再 build 看看。如果还是出现上述问题,那可能不是 antdocs 主题导致的。
另外,通过搜索引擎搜索相关信息,有几率是你的服务器负载问题,详情见:Centos7 因内存 可用大小不足,被killed的解决办法linux下运行脚本时出现killed怎么解决?

@LuBangTao
Copy link
Author

[/lannis/opt/book2.0/node_modules/core-js/library/fn/symbol/iterator.json]
[/lannis/opt/book2.0/node_modules/[email protected]@core-js/library/fn/symbol/iterator.styl.js]
[/lannis/opt/book2.0/node_modules/[email protected]@core-js/library/fn/symbol/iterator.styl.jsx]
[/lannis/opt/book2.0/node_modules/[email protected]@core-js/library/fn/symbol/iterator.styl.vue]
[/lannis/opt/book2.0/node_modules/[email protected]@core-js/library/fn/symbol/iterator.styl.json]
[/lannis/opt/book2.0/node_modules/[email protected]@core-js/library/fn/symbol/iterator.styl.styl]
[/lannis/opt/book2.0/node_modules/core-js/library/fn/symbol/iterator.styl]
 @ ./node_modules/[email protected]@babel-runtime/core-js/symbol/iterator.js 1:30-75
 @ ./node_modules/[email protected]@babel-runtime/helpers/typeof.js
 @ ./node_modules/[email protected]@ant-design-vue/es/auto-complete/index.js
 @ ./node_modules/[email protected]@ant-design-vue/es/index.js
 @ ./node_modules/[email protected]@vuepress-theme-antdocs/enhanceApp.js
 @ /usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/.temp/app-enhancers/0.js
 @ /usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/.temp/internal/app-enhancers.js
 @ /usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/lib/client/app.js
 @ /usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/lib/client/serverEntry.js
 @ multi /usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/lib/client/serverEntry.js
Error: Failed to compile with errors.
    at webpack (/usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/lib/node/build/index.js:180:16)
    at finalCallback (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/MultiCompiler.js:254:12)
    at runWithDependencies.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/MultiCompiler.js:277:6)
    at done (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@neo-async/async.js:2931:13)
    at runCompilers (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/MultiCompiler.js:181:48)
    at err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/MultiCompiler.js:188:7)
    at compiler.run (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/MultiCompiler.js:270:7)
    at finalCallback (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compiler.js:257:39)
    at hooks.done.callAsync.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compiler.js:273:13)
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/HookCodeFactory.js:33:10), <anonymous>:33:1)
    at AsyncSeriesHook.lazyCompileHook (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/Hook.js:154:20)
    at onCompiled (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compiler.js:271:21)
    at hooks.afterCompile.callAsync.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compiler.js:681:15)
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/HookCodeFactory.js:33:10), <anonymous>:6:1)
    at AsyncSeriesHook.lazyCompileHook (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/Hook.js:154:20)
    at compilation.seal.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compiler.js:678:31)
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/HookCodeFactory.js:33:10), <anonymous>:9:1)
    at AsyncSeriesHook.lazyCompileHook (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/Hook.js:154:20)
    at hooks.optimizeAssets.callAsync.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compilation.js:1423:35)
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/HookCodeFactory.js:33:10), <anonymous>:9:1)
    at AsyncSeriesHook.lazyCompileHook (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/Hook.js:154:20)
    at hooks.optimizeChunkAssets.callAsync.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compilation.js:1414:32)
[root@lannis book2.0]# 

我把服务器的占用内存大的关掉,然后重新打包。。。报了一页错,,看不到头的那种。你能帮我在看下么么

@LuBangTao
Copy link
Author

cnpm install core-js@2
上面那个问题 我重新安装了core-js就好了
然后打包 突然又好了。

就是系统内存不够的原因应该。我一直以为killed是打包过程输出的东西哦。。。谢谢

@zpfz
Copy link
Owner

zpfz commented Jun 10, 2020

[/lannis/opt/book2.0/node_modules/core-js/library/fn/symbol/iterator.json]
[/lannis/opt/book2.0/node_modules/[email protected]@core-js/library/fn/symbol/iterator.styl.js]
[/lannis/opt/book2.0/node_modules/[email protected]@core-js/library/fn/symbol/iterator.styl.jsx]
[/lannis/opt/book2.0/node_modules/[email protected]@core-js/library/fn/symbol/iterator.styl.vue]
[/lannis/opt/book2.0/node_modules/[email protected]@core-js/library/fn/symbol/iterator.styl.json]
[/lannis/opt/book2.0/node_modules/[email protected]@core-js/library/fn/symbol/iterator.styl.styl]
[/lannis/opt/book2.0/node_modules/core-js/library/fn/symbol/iterator.styl]
 @ ./node_modules/[email protected]@babel-runtime/core-js/symbol/iterator.js 1:30-75
 @ ./node_modules/[email protected]@babel-runtime/helpers/typeof.js
 @ ./node_modules/[email protected]@ant-design-vue/es/auto-complete/index.js
 @ ./node_modules/[email protected]@ant-design-vue/es/index.js
 @ ./node_modules/[email protected]@vuepress-theme-antdocs/enhanceApp.js
 @ /usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/.temp/app-enhancers/0.js
 @ /usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/.temp/internal/app-enhancers.js
 @ /usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/lib/client/app.js
 @ /usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/lib/client/serverEntry.js
 @ multi /usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/lib/client/serverEntry.js
Error: Failed to compile with errors.
    at webpack (/usr/node/lib/node_modules/vuepress/node_modules/_@[email protected]@@vuepress/core/lib/node/build/index.js:180:16)
    at finalCallback (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/MultiCompiler.js:254:12)
    at runWithDependencies.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/MultiCompiler.js:277:6)
    at done (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@neo-async/async.js:2931:13)
    at runCompilers (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/MultiCompiler.js:181:48)
    at err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/MultiCompiler.js:188:7)
    at compiler.run (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/MultiCompiler.js:270:7)
    at finalCallback (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compiler.js:257:39)
    at hooks.done.callAsync.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compiler.js:273:13)
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/HookCodeFactory.js:33:10), <anonymous>:33:1)
    at AsyncSeriesHook.lazyCompileHook (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/Hook.js:154:20)
    at onCompiled (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compiler.js:271:21)
    at hooks.afterCompile.callAsync.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compiler.js:681:15)
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/HookCodeFactory.js:33:10), <anonymous>:6:1)
    at AsyncSeriesHook.lazyCompileHook (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/Hook.js:154:20)
    at compilation.seal.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compiler.js:678:31)
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/HookCodeFactory.js:33:10), <anonymous>:9:1)
    at AsyncSeriesHook.lazyCompileHook (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/Hook.js:154:20)
    at hooks.optimizeAssets.callAsync.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compilation.js:1423:35)
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/HookCodeFactory.js:33:10), <anonymous>:9:1)
    at AsyncSeriesHook.lazyCompileHook (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@tapable/lib/Hook.js:154:20)
    at hooks.optimizeChunkAssets.callAsync.err (/usr/node/lib/node_modules/vuepress/node_modules/[email protected]@webpack/lib/Compilation.js:1414:32)
[root@lannis book2.0]# 

我把服务器的占用内存大的关掉,然后重新打包。。。报了一页错,,看不到头的那种。你能帮我在看下么么

core-js 问题请见 #5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants