How to sync your clock on Solaris

Posted in OpenSolaris, Solaris & OpenSolaris on May 29th, 2007 by Michal Bielicki

So you have your squeaky fresh solaris or solaris express install and the clock is all wrong. You want it to be correct allways, perfectly synced to the internet. I suggest you use the services of pool.ntp.org. Pool.ntp.org is a pool of servers that are publicly available for Network TIme Protocol requests on the internet.

So lets go for it

Create the file /etc/inet/ntp.conf and add the following to it:

driftfile /var/ntp/ntp.drift

server 0.pool.ntp.org
server 1.pool.ntp.org
server 2.pool.ntp.org

Now activate your ntp daemon:

svcadm enable ntp

et voila, your clock is allways up to date.

You can check your time differences with:

ntpq -p

which should give you an output like:

bash-3.00# ntpq -p
remote refid st t when poll reach delay offset disp
==============================================================================
admin.curacao.b ntp1.linx.net 2 u 44 64 1 25.57 1.529 15875.0
static.80.254.4 ns.tele.dk 2 u 44 64 1 37.51 -3.456 15875.0
ntp1.adviseo.ne clock.sjc.he.ne 2 u 44 64 1 25.42 -3.154 15875.0
bash-3.00#

Powered by ScribeFire.

Tags: , , , ,

When your mac suddenly gets a load you did not expected it could be your NAT running wild

Posted in Mac on May 28th, 2007 by Michal Bielicki

We all know and love internet connection sharing. I use it all the time. Mostly to conect other devices to some wifi network. Now from time to time I forget to switch it off and it runs on empty. Lately I found out that this is avery very bad idea. Natd seems to grow and grow in CPU usage when it runs ide and suddenly you have your macbook pro running hot and you have no idea why. So remember, when not using it, switch off that internet connection sharing or experience a really HOT box :)

Powered by ScribeFire.

Setting up your networking in Solaris 10 and Nevada if you had dhcp running before

Posted in OpenSolaris, Solaris & OpenSolaris on May 24th, 2007 by Michal Bielicki

OK,
I get asked this all the time on IRC so here a small intro.
First you need to find out the interfacename. If you originaly set your configuration to dhcp,
there will be 2 files around, which you must delete for setting up static network:

/etc/dhcp.INTERFACENAME
and
/etc/dhcp/INTERFACENAME.dhc

note the INTERFACENAME, we will need that.

So, now that we know the name of the interface, lets start with the basics.

Insert the hostname you want your machine to have into the file:
/etc/nodename

Insert the same hostname and ip address into the file /etc/hosts
Insert the same hostname into the file /etc/hostname.INTERFACENAME

delete the dhcp files we found in the beginning.
Insert the network name and the netmask into /etc/inet/netmasks
Insert your default router ip address into /etc/defaultrouter
add your nameservers to /etc/resolv.conf
copy /etc/nsswitch.dhcp over /etc/nsswitch.conf

now that all files are prepared
do the following:

pkill dhcpagent
svcadm restart network/physical

now lets check with ifconfig -a if the right interface has the right address
with hostname if the host name was set correctly
and with netstat -r -n if you have the right routes setup

voila, its all there and will stay after reboot

Powered by ScribeFire.

Tags: , , ,

dd-wrt and nokia smart/voip phones and truphone

Posted in VoIP on May 24th, 2007 by Michal Bielicki

dd-wrt seems to have problems with nokia smartphones trying to utilize sip services like truphone. If you happen to be a dd-wrt fan like me you will need to use v23-sp3 micro. That one works.

If someone has further clues why this is like it, please comment and I will try to pass that on to truphone and wherever else possible :)

Powered by ScribeFire.