Friday Feb 13, 2009

Mobile internet on OpenSolaris

I have a new mobile phone which is less steam driven than the one it replaces and, hopefully, will not power itself off and reset to factory defaults every few days. Being modern it can act as a USB modem device and therefore allows me to have my OpenSolaris Laptop work with it.

Following the instructions from James Leggs blog and some from an Email I had been sent (James' instructions were the same as the email) it all worked just fine except: The phone is a Nokia E71 and by default the USB setting was menu->connectivity->usb was set with "USB mode" to mass storage and "Ask on connection" to Yes. It seems that that was enough for OpenSolaris to see it as a disk drive and then not plumb up the serial devices. Changing the "USB mode" to "PC Suite" resolved this.

The only addition I have made was to add these scripts into /etc/ppp to disable nwam and fix resolv.conf when the link comes up and reverse that when it is taken down.

cjg@brompton:~$ cat /etc/ppp/ip-up
#!/bin/ksh -p

/usr/sbin/svcadm disable -t svc:/network/physical:nwam

mv /etc/resolv.conf /etc/resolv.conf.preppp

cp /etc/ppp/resolv.conf /etc/resolv.conf
chmod 644 /etc/resolv.conf
cjg@brompton:~$ 

and

cjg@brompton:~$ cat /etc/ppp/ip-down
#!/bin/ksh -p

test -f /etc/resolv.conf.preppp && mv /etc/resolv.conf.preppp /etc/resolv.conf

/usr/sbin/svcadm enable nwam
cjg@brompton:~$ 

Not rocket science and when nwam knows about ppp they will surely go but until then quite satisfactory.


Finally create a launcher that will start this at the click of a button. I have cheated here and simply have it starting in a terminal so I can stoop it by quitting the terminal:

cjg@brompton:~/Desktop$ cat 3G\\ network.desktop 

[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Terminal=true
Icon[en_GB]=/usr/share/icons/gnome/24x24/actions/call-start.png
Name[en_GB]=3G network
Exec=\\spfexec pppd call vodafone\\n
Name=3G network
Icon=/usr/share/icons/gnome/24x24/actions/call-start.png
cjg@brompton:~/Desktop$ 

Saturday Nov 29, 2008

Working around really really a small but irritating nwam bug

The euphoria over having a laptop that would suspend to RAM did not last long before it was shattered by a more real world situation. That is suspending while the wireless is connected, ie not when at my desk. This is bug 6766807 which is somewhat irritating and I'm sure will be resolved soon. With my work hat on I wonder if this could be one of the bugs that will be fixed in a supported update. However there is a simple work around.

#!/bin/ksh

function restart_nwam
{
	pfexec svcadm restart nwam
}
trap restart_nwam 35

while :
do
	sleep $((60\*60\*24))
done

Run that script as one of the programs started by the session and this problem is history. Obviously keep an eye on the bug so that when the fix is delivered you remove the work around. I'll update the bug with the workaround on Monday.

Monday May 21, 2007

Network Auto-Magic

Build 64 has allowed me to enable Network Auto-magic (NWAM) on my laptops. On my DELL Latitude D600 which has a Broadcom (bge) gigabit interface with a driver that supports Link and Interface Events it works well with the wired interface however with the wireless I have had to increase the “nwamd/dhcp_wait_time” smf property from 60 seconds to 120 so that it will work reliably. I can plug in the wired interface in and the wireless interface it taken down and the wired interface comes up. As it should be.

On the Toshiba which has an Intel network interface whose driver does not (yet) support Link and Interface Events the laptop always comes up with the wireless connection, which is less than ideal and would have been a pain when in Chicago but it is still better than not having it.

About

This is the old blog of Chris Gerhard. It has mostly moved to http://chrisgerhard.wordpress.com

Search

Archives
« May 2015
MonTueWedThuFriSatSun
    
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
       
Today