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

这里怎么执行的? #8

Open
asyncrun opened this issue Sep 24, 2021 · 1 comment
Open

这里怎么执行的? #8

asyncrun opened this issue Sep 24, 2021 · 1 comment

Comments

@asyncrun
Copy link

[root@iZbp1j690hvz1x9t0yq6ygZ soleTownServer]# ls
etc  luaclib  lualib  service  skynet  start.sh
[root@iZbp1j690hvz1x9t0yq6ygZ soleTownServer]# sh start.sh 
[skynet config]:17: ././etc/config.node: No such file or directory
[root@iZbp1j690hvz1x9t0yq6ygZ soleTownServer]# 

start.sh
./skynet/skynet ./etc/config.node$1

如果这样

[root@iZbp1j690hvz1x9t0yq6ygZ soleTownServer]# ./skynet/skynet ./etc/config.node1
[:00000002] LAUNCH snlua bootstrap
[:00000002] lua loader error : error loading module 'skynet' from file './skynet/luaclib/skynet.so':
 ./skynet/luaclib/skynet.so: undefined symbol: luaopen_skynet
stack traceback:
 [C]: in ?
 [C]: in function 'require'
 ./skynet/service/bootstrap.lua:1: in local 'main'
 ./skynet/lualib/loader.lua:48: in main chunk
[:00000002] KILL self
@luopeiyu
Copy link
Owner

用“sh start.sh 1”来调用,sh中的“$1”相当于获取“1”这个参数,所以实际折行的语句是“./skynet/skynet ./etc/config.node1”。

至于提示error loading module 'skynet',目测没有编译好skynet,建议重新编译一次。

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

No branches or pull requests

2 participants