Notices


Reply
Thread Tools
int_ua's Avatar
Posts: 676 | Thanked: 1,067 times | Joined on Jul 2010 @ Kyiv, Ukraine
#21
Originally Posted by vetsin View Post
can't I just comment out the first line with a "#"?
Is this about /etc/event.d/sshd?
IIRC, you can, it's a good idea, actually
 
int_ua's Avatar
Posts: 676 | Thanked: 1,067 times | Joined on Jul 2010 @ Kyiv, Ukraine
#22
0.3-2 Some refactoring and additional check for status after failed toggle. Looks like everything I wanted to add is ready, please confirm that it works.
 
int_ua's Avatar
Posts: 676 | Thanked: 1,067 times | Joined on Jul 2010 @ Kyiv, Ukraine
#23
0.4 Icon is back on freemangordon's request. Not shooting messages to your face unless something unusual happened. Will push that to extras.
 

The Following 3 Users Say Thank You to int_ua For This Useful Post:
Posts: 1,378 | Thanked: 1,604 times | Joined on Jun 2010 @ Göteborg, Sweden
#24
Thank you. It works.
 

The Following User Says Thank You to handaxe For This Useful Post:
Posts: 136 | Thanked: 263 times | Joined on Nov 2012 @ Germany
#25
I installed v 0.4 but it freezes the status menu when pressing its left button "ssh status". I tried v 0.19 instead and after pressing its button the status menu gets closed but then it cannot be opened anymore. I have CSSU installed v 21.2011.38-1Smaemo7. Any help?

Last edited by rasmarc; 2015-04-06 at 01:51.
 
int_ua's Avatar
Posts: 676 | Thanked: 1,067 times | Joined on Jul 2010 @ Kyiv, Ukraine
#26
Originally Posted by rasmarc View Post
I installed v 0.4 but it freezes the status menu when pressing its left button "ssh status". I tried v 0.19 instead and after pressing its button the status menu gets closed but then it cannot be opened anymore. I have CSSU installed v 21.2011.38-1Smaemo7. Any help?
Let's start with finding out your hildon-status-menu version:
Code:
dpkg -s hildon-status-menu | grep Version
 

The Following 2 Users Say Thank You to int_ua For This Useful Post:
Posts: 136 | Thanked: 263 times | Joined on Nov 2012 @ Germany
#27
Originally Posted by int_ua View Post
Let's start with finding out your hildon-status-menu version:
Code:
dpkg -s hildon-status-menu | grep Version
it says
Version: 0.3.40-8
 
int_ua's Avatar
Posts: 676 | Thanked: 1,067 times | Joined on Jul 2010 @ Kyiv, Ukraine
#28
Originally Posted by rasmarc View Post
Version: 0.3.40-8
Ok, that's the latest one. Have you tried reporting this bug against it? Unfortunately, I can't reproduce it.
Maybe try also asking on IRC:
https://wiki.maemo.org/IRC
 

The Following 2 Users Say Thank You to int_ua For This Useful Post:
Posts: 136 | Thanked: 263 times | Joined on Nov 2012 @ Germany
#29
I got v 0.19 working properly by making some changes to /usr/sbin/ssh-status.sh.

There was no problem with hildon-status-menu. It was just blocked as soon as the start/stop commands were executed. I discovered this by doing "killall sshd" from a terminal when the status menu was blocked.

So I added an ampersand '&' to the commands "start sshd" and "stop sshd" remembering a hint from peterleinchen in another thread. After that the status menu worked as usual. But two things didn't work reliable: starting ssh and detecting if ssh was running.

When starting ssh didn't work i executed "start sshd &" from a terminal which gave either "ssh respawning too fast" or "process terminated with status 255". After using "/etc/init.d/ssh start" instead of "start sshd &" and adding a "sleep 1" it kept working.

And detecting status of ssh using "status sshd" resp. "status sshd | grep -c running" sometimes gave "0" although ssh was running. As an alternative i found "ps aux | grep -c /usr/sbin/sshd" working reliable.

Additionally i replaced "stop sshd &" with "killall sshd", because i don't need connections kept alive when stopping ssh. And finally i changed the messages confirming start/stop from being dialogs disappearing only if pressed to "infoprints" at the top of the screen disappearing automatically. I copied the relevant code from ade's cooktimer.
Attached Files
File Type: gz ssh-status.sh.tar.gz (1.1 KB, 44 views)
 

The Following User Says Thank You to rasmarc For This Useful Post:
int_ua's Avatar
Posts: 676 | Thanked: 1,067 times | Joined on Jul 2010 @ Kyiv, Ukraine
#30
Originally Posted by rasmarc View Post
And detecting status of ssh using "status sshd" resp. "status sshd | grep -c running" sometimes gave "0" although ssh was running. As an alternative i found "ps aux | grep -c /usr/sbin/sshd" working reliable.
The link to the updated source is the first thing in the thread: https://gitorious.org/n900-ssh-statu...:ssh-status.sh

If you had checked it, you would have known that I've rewritten it too and that I've switched to
Code:
`pidof sshd` -gt "0"
 
Reply


 
Forum Jump


All times are GMT. The time now is 09:30.