Linux

Upgrade from Fedora Core 7 to Core 8

This is the steps I took to upgrade a running Fedora Core 7 installation to Core 8 using yum from the command line. Please note that live upgrades are not recommended by the Fedora Project. Make a list of the systems current packages for later reference: rpm -qa –qf ‘%{NAME}\n’ | sort | uniq > […]

Read More
Network

Create virtual / alias IP address

This is the code to make an alias IP address on network interface ethX where X is a number to indicate the device we are attaching the IP. ifconfig eth0:1 192.168.0.30 netmask 255.255.255.0 up Your machine will now answer on ping requests 192.168.0.30. You can see the result by running the command ifconfig eth0:1 Result […]

Read More
Linux

Deny SSH- but allow SFTP access

This is an alternative way of limiting the SSH access to only SFTP explained in my How to restrict users to SFTP only instead of SSH post.Edit your /etc/sshd_config file and change your settings like thisMatch User usernameAllowTcpForwarding noX11Forwarding noForceCommand /usr/libexec/sftp-server -l INFO Replace username with the user name you would limit the SSH access […]

Read More
Linux

Query RPM database/packages and list their architecture

If you use the –queryformat argument with rpm it is possible to query RPMs for different architectures installed# rpm -qa –queryformat %{NAME}-%{VERSION}-%{ARCH}\\n | grep dbus-glib | sortResultdbus-glib-0.22-12.EL.5-i386dbus-glib-0.22-12.EL.5-x86_64This can also be used in one of my previous posts: Remove duplicate packages when querying the rpm database.

Read More
Scripting

Convert videos to 3gp format

This bash script converts videos like AVI-files to the 3gp format used on newer cell phones like Nokia N95. To use it you should have the libamr_nb and libamr_nw flags available to ffmpeg.< /p> ffmpeg -formats |grep amrFFmpeg version SVN-rUNKNOWN, Copyright (c) 2000-2007 Fabrice Bellard, et al. ¬†configuration: –prefix=/usr –libdir=/usr/lib –shlibdir=/usr/lib –mandir=/usr/share/man –enable-static –enable-shared –cc=i686-pc-linux-gnu-gcc […]

Read More