Skip to main content

Posts

Project: Btrfs - new file system from Oracle

Linux has a wealth of file systems to choose from, but we are facing a number of challenges with scaling to the large storage subsystems that are becoming common in today's data centers. File systems need to scale in their ability to address and manage large storage, and also in their ability to detect, repair and tolerate errors in the data stored on disk. So Oracle is creating a new file system: btrfs. Read more...

Force user to change password on first login

Funny, I was searching for this last Summer but couldn't find a good way then. Now, I found instructions on Red Hat for forcing a Linux user to change his password on first login ! It's easy too and along the lines I was thinking then, but simply couldn't put together. Create the user, set a password, lock the account, use chage and unlock the account...

Emergency Disk Recovery on Linux

While developing a script for Oracle Enterprise Manager (OEM) that checks the file system on our servers, I saw the /var on my (NIS) test VM was corrupt. No idea how it had happened but I decided to test my utils out. In doing so, I ran e2fsck -n /dev/mapper/vgsystem-lvvar and it created a whole slew of error messages. Zero inodes, bad dates, orphaned inodes, etc. So I let e2fsck fix them using e2fsck -y /dev/mapper/vgsystem-lvvar ... One of the things I saw run by me was "...erasing journal... device is now ext2" or something. <enter panic mode> thankfully Mandriva has a good Emergency Recovery section . It pointed me to some useful utilities. If you have a bad superblock, try the switch for e2fsck -b 8193 first. There may be a perfectly good backup available. When you delete the ext3 journal, tune2fs -j device recreates it for you and rescuept can scan bad partitions for try to make sense of them...

mrepo configuration

Found a good site that explains the mrepo configuration on setting up an apt/yum repository from ISO images, online updates, patches and custom packages... Looks to be very cool and much more flexible than Oracle's own ULN local mirror function...

mrepo: yum/apt repository mirroring

Just thought I'd mention this as this is the first time I ran into this... On Oracle Linux, just as on Fedora, CentOS and Red Hat, you usually install software using either up2date (blah) or yum (much better). However, setting up a local mirror for network installs or local updates, is somewhat daunting. Especially when used to the comfortable ease of Debian-based distos as they have all sources available for free on the net. Therefore it nice to know that some dedicated fellows like Dag Wieers use their time to make life a little easier for you. With tools like mrepo: yum/apt repository mirroring (formerly known as 'yam'). I haven't played with this yet, but I'm gonna look into it for sure!

Preventing PuTTY timeouts

Just found a great tip to prevent timeouts of PuTTY sessions. I'm fine with timeouts by the host, but in our case the firewall kills sessions after 30 minutes of inactivity... When using PuTTY to ssh to your Linux/Unix servers, be sure to use the feature to send NULL packets to prevent a timeout. I've set it to once every 900 seconds, i.e. 15 minutes... See screenshot on the right.

Debugging sudoers

At last I found a way to debug the usage of sudo and my sudoers file! It was there all along but I must have overlooked it million times... When using the option -l for sudo, you get a listing of the allowed and forbidden commands for that user on that host. Thanks to the [sudo-users] list for showing the light. As there was no mention of the word "debug" anywhere in the man page, I simply overlooked that option all together... *sigh*