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

Won't run on Linux (Debian based) #11

Closed
EwanValentine opened this issue Sep 17, 2013 · 18 comments
Closed

Won't run on Linux (Debian based) #11

EwanValentine opened this issue Sep 17, 2013 · 18 comments

Comments

@EwanValentine
Copy link

running learnyounode doesn't return anything in terminal in Linux Mint 15 (fresh install of node.js)

@rvagg
Copy link
Contributor

rvagg commented Sep 17, 2013

Can you give any more information about this? Any error messages? Any problems installing? What exactly does it do, or not do and what version of Node are you using?

(learnyounode was mainly developed on Ubuntu btw and should work across all major platforms supporting Node).

@sidorares
Copy link
Member

Also, which terminal emulator you are using? (+ node version) Works for me in Mint 14

@EwanValentine
Copy link
Author

Hi guys,

I'm using node v0.10.18 on Mint 15, running the standard terminal. I followed the instruction here to install the more recent node as I was previously running a much older version:
https://github.com/joyent/node/wiki/Installing-Node.js-via-package-manager

Cheers,

Ewan

@rvagg
Copy link
Contributor

rvagg commented Sep 20, 2013

can you give us a screenshot or something? perhaps let us know what echo $TERM gives you. Also make sure your terminal is large enough, it should be somewhere >= 80 chars wide to fit it on, although even if it's skinnier than that it'll just wrap and be ugly.

@bobholt
Copy link

bobholt commented Sep 20, 2013

Works for me on node v0.10.18 on Mint 15 in standard gnome-terminal (xterm). A screenshot or other error information would help troubleshoot, @EwanValentine.

But as a shot in the dark, did you remember the -g in npm install -g learnyounode?

@EwanValentine
Copy link
Author

'echo $TERM' outputs 'xterm'

Yeah I used the -g flag, had to sudo it. I wish I could give more info but when I run the command 'learnyounode' it just moves down onto the next line. There must be a conflict of some description on my laptop

Cheers,

Ewan

@ralphtheninja
Copy link
Member

@EwanValentine Hmm, does it work if you do 'sudo learnyounode' ?

@EwanValentine
Copy link
Author

No luck! Does the same :S

@sidorares
Copy link
Member

and last resort, strace learnyounode :)

@ralphtheninja
Copy link
Member

I'd do the following as well:

npm remove -g learnyounode
npm cache clean
npm install -g npm
npm install -g learnyounode

@EwanValentine
Copy link
Author

Ran that re-install, no luck.

Here's the strace results, prepare your eyes!

execve("/usr/bin/learnyounode", ["learnyounode"], [/* 53 vars /]) = 0
brk(0) = 0x7e9000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7feda41a3000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=106534, ...}) = 0
mmap(NULL, 106534, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7feda4188000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\260\37\2\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1848024, ...}) = 0
mmap(NULL, 3961912, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7feda3bbb000
mprotect(0x7feda3d79000, 2093056, PROT_NONE) = 0
mmap(0x7feda3f78000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1bd000) = 0x7feda3f78000
mmap(0x7feda3f7e000, 17464, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7feda3f7e000
close(3) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7feda4187000
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7feda4185000
arch_prctl(ARCH_SET_FS, 0x7feda4185740) = 0
mprotect(0x7feda3f78000, 16384, PROT_READ) = 0
mprotect(0x605000, 4096, PROT_READ) = 0
mprotect(0x7feda41a5000, 4096, PROT_READ) = 0
munmap(0x7feda4188000, 106534) = 0
brk(0) = 0x7e9000
brk(0x80a000) = 0x80a000
open("/usr/lib/locale/locale-archive", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=7212544, ...}) = 0
mmap(NULL, 7212544, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7feda34da000
close(3) = 0
execve("/home/ewanvalentine/.rvm/gems/ruby-1.9.3-p448/bin/node", ["node", "/usr/bin/learnyounode"], [/
53 vars /]) = -1 ENOENT (No such file or directory)
execve("/home/ewanvalentine/.rvm/gems/ruby-1.9.3-p448@global/bin/node", ["node", "/usr/bin/learnyounode"], [/
53 vars /]) = -1 ENOENT (No such file or directory)
execve("/home/ewanvalentine/.rvm/rubies/ruby-1.9.3-p448/bin/node", ["node", "/usr/bin/learnyounode"], [/
53 vars /]) = -1 ENOENT (No such file or directory)
execve("/home/ewanvalentine/.rvm/bin/node", ["node", "/usr/bin/learnyounode"], [/
53 vars /]) = -1 ENOENT (No such file or directory)
execve("/usr/local/sbin/node", ["node", "/usr/bin/learnyounode"], [/
53 vars /]) = -1 ENOENT (No such file or directory)
execve("/usr/local/bin/node", ["node", "/usr/bin/learnyounode"], [/
53 vars /]) = -1 ENOENT (No such file or directory)
execve("/usr/sbin/node", ["node", "/usr/bin/learnyounode"], [/
53 vars */]) = 0
brk(0) = 0x13ed000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f99683fb000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=106534, ...}) = 0
mmap(NULL, 106534, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f99683e0000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/usr/lib/libax25.so.0", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\240%\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=39496, ...}) = 0
mmap(NULL, 2135488, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f9967fd1000
mprotect(0x7f9967fda000, 2093056, PROT_NONE) = 0
mmap(0x7f99681d9000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x8000) = 0x7f99681d9000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/usr/lib/libax25io.so.0", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\20\r\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=10264, ...}) = 0
mmap(NULL, 2109664, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f9967dcd000
mprotect(0x7f9967dcf000, 2093056, PROT_NONE) = 0
mmap(0x7f9967fce000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1000) = 0x7f9967fce000
mmap(0x7f9967fd0000, 224, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f9967fd0000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\260\37\2\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1848024, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f99683df000
mmap(NULL, 3961912, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f9967a05000
mprotect(0x7f9967bc3000, 2093056, PROT_NONE) = 0
mmap(0x7f9967dc2000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1bd000) = 0x7f9967dc2000
mmap(0x7f9967dc8000, 17464, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f9967dc8000
close(3) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f99683dd000
arch_prctl(ARCH_SET_FS, 0x7f99683dd740) = 0
mprotect(0x7f9967dc2000, 16384, PROT_READ) = 0
mprotect(0x7f9967fce000, 4096, PROT_READ) = 0
mprotect(0x7f99681d9000, 4096, PROT_READ) = 0
mprotect(0x60d000, 4096, PROT_READ) = 0
mprotect(0x7f99683fd000, 4096, PROT_READ) = 0
munmap(0x7f99683e0000, 106534) = 0
rt_sigaction(SIGALRM, {0x404db0, [ALRM], SA_RESTORER|SA_RESTART, 0x7f9967a3c0b0}, {SIG_DFL, [], 0}, 8) = 0
rt_sigaction(SIGTERM, {0x404db0, [TERM], SA_RESTORER|SA_RESTART, 0x7f9967a3c0b0}, {SIG_DFL, [], 0}, 8) = 0
rt_sigaction(SIGINT, {0x404db0, [INT], SA_RESTORER|SA_RESTART, 0x7f9967a3c0b0}, {SIG_DFL, [], 0}, 8) = 0
rt_sigaction(SIGQUIT, {0x404db0, [QUIT], SA_RESTORER|SA_RESTART, 0x7f9967a3c0b0}, {SIG_DFL, [], 0}, 8) = 0
rt_sigaction(SIGSEGV, {0x404db0, [SEGV], SA_RESTORER|SA_RESTART, 0x7f9967a3c0b0}, {SIG_DFL, [], 0}, 8) = 0
rt_sigaction(SIGPIPE, {SIG_IGN, [PIPE], SA_RESTORER|SA_RESTART, 0x7f9967a3c0b0}, {SIG_DFL, [], 0}, 8) = 0
socket(PF_FILE, SOCK_DGRAM, 0) = 3
brk(0) = 0x13ed000
brk(0x140e000) = 0x140e000
open("/proc/net/dev", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f99683fa000
read(4, "Inter-| Receive "..., 1024) = 570
ioctl(3, SIOCGIFHWADDR, {ifr_name="eth0", ifr_hwaddr=b8:88:e3:a4:b4:9c}) = 0
ioctl(3, SIOCGIFHWADDR, {ifr_name="lo", ifr_hwaddr=00:00:00:00:00:00}) = 0
ioctl(3, SIOCGIFHWADDR, {ifr_name="wlan0", ifr_hwaddr=68:94:23:44:48:89}) = 0
read(4, "", 1024) = 0
close(4) = 0
munmap(0x7f99683fa000, 4096) = 0
open("/etc/ax25/axports", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0644, st_size=200, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f99683fa000
read(4, "# /etc/ax25/axports\n#\n# The form"..., 4096) = 200
read(4, "", 4096) = 0
close(3) = 0
close(4) = 0
munmap(0x7f99683fa000, 4096) = 0
open("/etc/localtime", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=3661, ...}) = 0
fstat(3, {st_mode=S_IFREG|0644, st_size=3661, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f99683fa000
read(3, "TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\7\0\0\0\7\0\0\0\0"..., 4096) = 3661
lseek(3, -2338, SEEK_CUR) = 1323
read(3, "TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\10\0\0\0\10\0\0\0\0"..., 4096) = 2338
close(3) = 0
munmap(0x7f99683fa000, 4096) = 0
getpid() = 8501
socket(PF_FILE, SOCK_DGRAM|SOCK_CLOEXEC, 0) = 3
connect(3, {sa_family=AF_FILE, path="/dev/log"}, 110) = 0
sendto(3, "<187>Sep 20 11:57:51 node[8501]:"..., 62, MSG_NOSIGNAL, NULL, 0) = 62
exit_group(1) = ?

Judging by that, it does seem to be a folder or permission issue, I suspect?

@ralphtheninja
Copy link
Member

I would advice against using sudo when installing node. Just causes more problems with permissions etc.

@thehack
Copy link
Contributor

thehack commented Sep 20, 2013

Does 'node -v' definitely show v0.10.18? I had an issue on Ubuntu yesterday and came to realise I was not running node from where I thought I was. I had to 'sudo apt-get remove node'.

@EwanValentine
Copy link
Author

I think you're probably right, I've just noticed something else quirky which makes me think it's probably actually my install of node. Node doesn't return anything, but nodejs does! node -v == 0 whereas nodejs returns the version number... I think I need to re-install node and try again.

As I think it's probably my node installation, I'll re-install and try again, I'll close the issue as it's my node. Cheers for all your help!

@davidbanham
Copy link

The default Ubuntu package installs as nodejs for some reason, I suspect
the Debian package is doing the same.

If you're running Ubuntu use Chris Lea's PPA. Otherwise it's pretty
painless to build from source.
On 20 Sep 2013 21:34, "Ewan Valentine" notifications@github.com wrote:

I think you're probably right, I've just noticed something else quirky
which makes me think it's probably actually my install of node. Node
doesn't return anything, but nodejs does! node -v == 0 whereas nodejs
returns the version number... I think I need to re-install node and try
again.

As I think it's probably my node installation, I'll re-install and try
again, I'll close the issue as it's my node. Cheers for all your help!


Reply to this email directly or view it on GitHubhttps://github.com//issues/11#issuecomment-24804414
.

@sidorares
Copy link
Member

@RahulSDeshpande
Copy link

Hi all..

Seems like I solved this issue..

Thanks to @sidorares..

The solution for @EwanValentine's issue is:

You need to remove 'node' application from your Linux [may be Debian]..

sudo apt-get remove node

As I think, terminal may be getting confused between node & nodejs..

Command learnyounode will work perfectly as it worked for me :P

Please do comment if any further issues.. :)

Cheers..
Happy Coding..

@Salutz
Copy link

Salutz commented Feb 20, 2019

when you install learnyounode with
npm -g install learnyounode
it will list the installation directory as a path from your home directory just copy and paste the full install path into the command line and you should get learnyounode to run.
for example;
/home/yourusername/.node_modules_global/learnyounode
You can also add this to your $PATH environment variable then all you have to type is learnyounode at the command line

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

9 participants