PDA

Bekijk de volledige versie : "screen" - could not write to /opt/var/run/utmp bad file descriptor



patrickquek
14-04-2007, 11:14
Hi,

I followed the tutorial at http://wl500g.info/showthread.php?t=7643 in setting up screen in order that I may install enhanced c-torrent.

However I got stuck after installing "screen". What i did is as follows (using sudo bash):
1. ipkg install -force-overwrite ncurses
2. ipkg install -force-overwrite ncursesw
3. ipkg install -force-overwrite termcap
4. ipkg install -force-overwrite screen

The above steps completed without errors.

However when i execute "screen", i get the message:
could not write to /opt/var/run/utmp : bad file descriptor

So i went ahead to "touch /opt/var/run/utmp" to create utmp.

No good. I tried creating utmp as a directory in /opt/var/run/ as well but no difference.

What am i doing wrong?

Would appreciate any advice.

thanks.
Patrick

patrickquek
14-04-2007, 11:28
Did some trial and errors and found the solution:

The missing file should be "/var/run/utmp" rather than "/opt/var/run/utmp" !!!

Solved it with "touch /var/run/utmp".

:D :D :D

KGy
14-04-2007, 20:17
Hi!

touch /opt/var/run/utmp solve this problem but when I run 'screen' I get the message:

Cannot find termcap entry for 'xterm'.

What? And also not working nano editor:

Error opening terminal: xterm.

George:mad:

kfurge
15-04-2007, 03:25
Install the termcap package.

- K.C.

KGy
15-04-2007, 13:57
Hi,

termcap package already installed and updated...

nano already working my system but when I switch to oleg-optware feed (/opt/etc/ipkg.conf) and install uclibc-opt, libstdc++ and reinstall any already installed packages (and install wxbase and amule), screen and nano not working.
(xterm : unknown) I think uclibc-opt or libstdc++ lib files modified something my system or perhaps two termcap conf file in system... I :mad: mc is working and I can edit conf files (use xterm emulation)

sorry my english

Thanks, George

kfurge
17-04-2007, 03:02
Do you have /opt/lib in your LD_LIBRARY_PATH?

- K.C.

KGy
17-04-2007, 10:07
Yes but not run nano and screen.

George

kfurge
18-04-2007, 01:46
Sorry, I'm out of ideas...

- K.C.

wannaplay
10-05-2007, 19:27
termcap package already installed and updated...

nano already working my system but when I switch to oleg-optware feed (/opt/etc/ipkg.conf) and install uclibc-opt, libstdc++ and reinstall any already installed packages (and install wxbase and amule), screen and nano not working.
(xterm : unknown) I think uclibc-opt or libstdc++ lib files modified something my system or perhaps two termcap conf file in system... I :mad: mc is working and I can edit conf files (use xterm emulation)


to get nano and screen working again after switching to oleg-optware feedware run the command:

awk '/^Package:/{system("ipkg install -force-reinstall -force-defaults " $2)}' /opt/lib/ipkg/status

Original source http://wl500g.info/showthread.php?p=48520&highlight=xterm#post48520

mihaitintea
27-08-2009, 07:34
The following worked for me:

sudo touch /opt/var/run/utmp
sudo chmod -R 777 /opt/var/run

Then "screen" did not display the error message any more.