NIS tips
useful stuff for getting solaris to be a nis client - ypinit for the setup stuff, and ypstart to start the client up (ypbind)
useful stuff for getting solaris to be a nis client - ypinit for the setup stuff, and ypstart to start the client up (ypbind)
routing table additions on Solaris can be put in /etc/init.d/inetsvc so they happen at system startup. see bottom of file for examples.
Update - Actually, this is a crap place to put the entries as patches and OS updates can overwrite it (despite that I still see it a lot). A much better way is to add a staticrouting script to /etc/init.d/ looking something like this:
#!/sbin/sh
#
# Script - staticroutes.sh
#
case "$1" in
'start')
# Route for XX
/usr/sbin/route add 10.11.12.0/24 10.11.12.1
# Route for YY
/usr/sbin/route add 172.16.0.0 -netmask 255.255.0.0 172.16.0.1
;;
'stop')
# Route for XX
/usr/sbin/route delete 10.11.12.0/24 10.11.12.1
# Route for YY
/usr/sbin/route delete 172.16.0.0 -netmask 255.255.0.0 172.16.0.1
;;
*)
echo "Usage: $0 { start | stop }"
exit 1
;;
esac
exit 0
when does a ring become a tube? is a tube a long ring? is a ring a short tube?
to set date on solaris eg 040218122002
'Those who do not understand Unix are condemned to reinvent it, poorly.' -- Henry Spencer
to send attachments from the command line -
uuencode (filename) (filename) | mailx (address)
excellent page on why not to use frames - http://www.html-faq.com/htmlframes/?framesareevil
useful command line perl for doing a grep but only returning the matched string, not the whole line:
cat filename | perl -ne 'if($_ =~ /regexpr/) { print('$&
');}'
can't help thinking you should be able to do this with grep...
one way of finding out what type of processor your Sun machine has (assuming you are running Solaris) :
# psrinfo -r
to ensure NIS doesn't start automatically on a Solaris machine, rename /usr/lib/netsvc/yp/ypbind to something like /usr/lib/netsvc/yp/ypbind.orig. why isn't there an rc script to stop/start/disable it?
those damn modem commands you can never remember - http://www.modems.com/glossary/extend2b.html
to disable NIS (ypbind) from starting on a Solaris machine, just rename -
/usr/lib/netsvc/yp/ypstart
to something else.
trying to rm that file with a '-' at the start of its name? :
rm -- -foo
where -foo is the filename. apparently -- tells rm not to treat the rest of the arguments as parameters. i'm also told that this works for other common UNIX commands, cp etc.
solaris - how to allow users to chgrp (and presumably chown) files to other users -
in /etc/system :
set rstchown = 0
this entry is testimony to the fact that FreeBSD 5.0 RELEASE is at least stable enough to get Gnome going and Mozilla. Just about to have a go at Evolution.
interesting article in the Independent about Spain's ID card system.
neat. existence of this file means that non root users are prevented from logging in, even from the console. instead the contents of the file are displayed.
mounting an ISO image file in Solaris 8:
# /usr/sbin/lofiadm -a /path/to/iso/file /dev/lofi/1
# mount -F hsfs /dev/lofi/1 /path/to/mount/point
don't forget to remove the lofi device after you unmount:
# umount /path/to/mount/point
# /usr/sbin/lofiadm -d /dev/lofi/1
# man lofiadm
for more details
FreeBSD equivalent is nicely documented in the handbook.
the Melbourne Symphny Orchestra recently accompanied Kiss in concert. ridiculous, but i wish I'd been there.
useful doc at sun packed with information about nis - http://docs.sun.com/db/doc/806-1387/6jam692c8?a=view
Build your own eboy style cities with City Creator
Disable (and I suppose re-enable) STOP-A mechanism on a Sun/Solaris machine - http://www.netsys.com/sunmgr/1999-04/msg00041.html
I was walking past one of those soap box speakers in Leicester square a while back just as he had asked a question of the crowd. I didn't hear what the question was, but I did hear that he was asking people to put their hand up if they agreed. I saw nobody with their hand up so I thrust mine into the air, and waved it a little for good measure. He looked rather disgruntled as he noticed me, then waved his hand in my direction and said something like, ok so we have one person who agrees, BUT STILL! I walked off at that point. I've wondered since what I'd actually agreed to, but I like to think that I helped create a slightly more balanced view of whatever it was.
Hayao Miyazaki has outdone himself with Spirited Away, what an incredible imagination. This puts the normal Disney output to shame, making it look bland and boring (and no awful Phil Collins soundtrak either). I've been a fan of Miyazaki ever since I saw Crimson Pig and Lupin III a few years ago.
Recently discovered - JASS, Sun's own Solaris hardening scripts. They look pretty thorough, and fit nicely into the Jumpstart mechanism.
iTerm is a replacement for the standard OSX terminal application. It is faster (doesn't make it seem you are typing through treacle), has tabs, bookmarks, and is generally pretty cool.
At last, simple when you know how :
dtterm -xrm *menuBar:False
This makes use of X resources. You could also put the resource in your default .XResources file.
Tai Chi is great for focussing the mind, except today I was still focussed on why my syslogger wasn't logging anything and not concentrating on my 'grasp sparrow's tail'. Then I remembered the syslogger's main gotcha - spaces. Solaris' syslog daemon has trouble parsing config lines with space delimiting fields. Replace with tabs and it all works fine. Stupid really, it's the sort of thing that could make a real mess of your 'wave hands like clouds' if you couldn't figure it out.
Some instructions on how to change the screen resolution / colour depth on a Sun machine - http://www.unixgods.org/~tilo/sun_resolution.html
I've been looking for a way of multiplexing several ssh sessions. By that I mean the ability to type once, and the result happens in x ssh sessions. Thanks to someone on the FreeBSD UK user list I came across cssh (http://freshmeat.net/projects/cssh/). This does pretty much what I need, and so far I've had no problems with it.
What would be ideal though is functionality built into the window manager to do the same thing, so I 'tag' any number of windows, even varying applications, and my keyboard input, (maybe even mouse) is copied to all windows. For instance I could be typing into 3 ssh sessions and an instance of vi to record my typing.
Discovered a new way to copy a whole partition in Solaris:
ufsdump 0f - /dev/rdsk/d1 | (cd /mnt/d1 ; ufsrestore xf -)
where:
/dev/rdsk/d1 is the raw device, must be unmounted
/mnt/d1 is the destination for the data
This page contains an archive of all entries posted to numbersix in the Solaris category. They are listed from oldest to newest.
FreeBSD is the previous category.
art is the next category.
Many more can be found on the main index page or by looking through the archives.