Active Topics

 


Reply
Thread Tools
Posts: 18 | Thanked: 0 times | Joined on Jan 2010
#1
I have installed OpenSSH (server + client) on my N900 to login from my laptop and it works when I use the IP address. To make it a little easier to login, i started playing with avahi-daemon to be able to login with a hostname instead of the ip address. After googling a bit i found this page: http://thpmaemo.blogspot.com/2008/11...-on-maemo.html. It says that, by default, Avahi doesn't seem to work because it is started before D-Bus (the article says that both D-Bus and avahi start with an S20-script, but on my N900 avahi is started with an S14 script, while D-Bus with S20). After i manually started the avahi-daemon (with /etc/init.d/avahi-daemon start), i could remotely login with SSH by using the hostname instead of the ip-address.

So now i'm thinking about renaming S14avahi-daemon to S21avahi-daemon so it is started after D-Bus. I have also modified /etc/init.d/avahi/avahi-daemon.conf to change the hostname to something easier to remember, instead of the default Nokia-N90051-1.
However, on http://wiki.maemo.org/OTA_to_PR1.1_troubleshooting, I read about the possibilities of breaking OTA updates. Are changes like safe to do or will they help to break the future OTA updates?

I'm also wondering how heavy it is to run OpenSSH and avahi (on battery). If i just let the services run during one day without connecting/using them during that day, will it reduce my battery life with hours, or rather just a few minutes?
 
Posts: 40 | Thanked: 12 times | Joined on Dec 2007 @ Los Angeles
#2
I haven't gotten avahi to work correctly on my n900, yet, but have avahi on my n8x0 tablets...
Yes, rename the S14 and ?S16? avahi scripts to S21 (that is what worked on my tablets).
I don't think that I ever modified the avahi...conf file, just my hosts and hostname to give the tablets friendly names -- I don't recall if avahi propagated it...
Never noticed a significant battery drain from avahi/ssh (once again on the tablets).
 
Posts: 18 | Thanked: 0 times | Joined on Jan 2010
#3
Originally Posted by crenquis View Post
I haven't gotten avahi to work correctly on my n900, yet, but have avahi on my n8x0 tablets...
Yes, rename the S14 and ?S16? avahi scripts to S21 (that is what worked on my tablets).
I don't think that I ever modified the avahi...conf file, just my hosts and hostname to give the tablets friendly names -- I don't recall if avahi propagated it...
Never noticed a significant battery drain from avahi/ssh (once again on the tablets).
I have renamed both the S14-.. and S16-.. files to be S21-... I have also modified the hostname and hosts files to change the hostname and restored the avahi....conf file to its original state. However after i rebooted the phone (tested twice) i still have to start the avahi service manually. Any ideas on how it can be started automatically? thx!
 
Posts: 46 | Thanked: 25 times | Joined on Nov 2009 @ Michigan, USA
#4
Sorry for the bump, but...

Did anyone ever figure avahi on the N900? I've been trying different setups for the past couple hours now, and I can't really get it to work. My computer sees the phone's .local hostname, but the phone doesn't see the computer.

Pinging Nokia-N900.local from my computer works, but pinging computer.local, or even nokia-n900.local itself from the N900 gives me a "bad address" error.

Last edited by fwrnando; 2010-10-10 at 07:57.
 
Posts: 87 | Thanked: 47 times | Joined on Sep 2009 @ Sorocaba, Brasil
#5
Hi fwrnando,

it seems to be working for me here in my N900, but I had to:
  1. Install libnss-mdns as explained in this thread http://talk.maemo.org/showthread.php?t=24578
  2. Edit /etc/nsswitch.conf and change the hosts line from:
    hosts: files dns
    to:
    hosts: files mdns4_minimal [NOTFOUND=return] dns mdns4
  1. I install avahi-utils package
  2. Within a terminal I issue avahi-discover and it shows me the list of local available zeroconf servers, my notebook is avertised among them as "daniel-VGN-FZ21S.local"
  3. I issue "avahi-resolve -4 -n daniel-VGN-FZ21S.local" and it gives me the ip of my notebook as expected.
  4. "ssh daniel@daniel-VGN-FZ21S.local" works as expected

No no more need to manually look up or hardcode ips in my DHCP server.
 

The Following 2 Users Say Thank You to dalonso For This Useful Post:
Posts: 46 | Thanked: 25 times | Joined on Nov 2009 @ Michigan, USA
#6
Thanks for the reply! I got it working now, didn't even have to edit nsswitch.conf as was already installed like that.

Makes me wonder why libnss-mdns isn't in the repositories, or already bundled with maemo, for that matter.
 
Reply


 
Forum Jump


All times are GMT. The time now is 19:34.