Jared |

CAT | Linux/Unix

I was eager to try out the recently released Fedora 16 Linux distribution and I’m glad I did. Like a lot of new Linux distros Fedora is using the updated Gnome 3 shell which has divided a lot of users between those who figure out a new desktop with 3 and those that stay with the well known 2. While Ubuntu is probably the distro most users new to Linux try, Fedora might take a little more umph to kickstart. For example, it doesn’t come with the mp3 codec nor various important video codecs. Also, Fedora 16 comes with a open source video driver called Nouveau. Nouveau may do fine for basic tasks, but if you want to really unlock the capabilities of your 1gb NVIDIA mega video card, you’ll have to disable Nouveau and install some new drivers.

NVIDIA Drivers
Credits: http://forums.fedoraforum.org/showthread.php?t=204752 from “leigh123linux”.
This is only for GeForce 6, 7, 8, 9, 200, 300, 400 & 500 series cards, not Geforce MX cards.
1. I had 2 video cards installed at first and so things weren’t set up right at first. If you’ve installed Fedora 16 and are sitting at a garbled video screen press Ctrl + Alt + F1-F7 (try each F1 to F7 key to get to a command prompt).
2. Type “init 3” to get set your system to runlevel 3 (it quits X11, probably your Linux GUI of choice).
3. Login as root “su -“. Type password.
4. Configure X11. Type Xorg -configure. Then reboot. This steps configures X11 and detects all video cards in your system.
5a. akmod (Supposed to be better for when a new kernel is released.)
5aa. If you use the PAE kernel do this before 5ab:
yum install kernel-PAE-devel

5ab. su (if you haven't already logged in as root)
yum --nogpgcheck install http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm
yum install akmod-nvidia xorg-x11-drv-nvidia-libs.i686

5b. kmod (Saves disk space but will likely have problems when the kernel is updated.)
5ba. If you use a PAE kernel
yum --nogpgcheck install http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm
yum install kmod-nvidia-PAE

5bb. Else,
yum --nogpgcheck install http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm
yum install kmod-nvidia xorg-x11-drv-nvidia-libs.i686

6. Remove nouveau from initramfs
mv /boot/initramfs-$(uname -r).img /boot/initramfs-$(uname -r)-nouveau.img
dracut /boot/initramfs-$(uname -r).img $(uname -r)

7. Reboot

Other Notes:
- Grub location in Fedora 16: /boot/grub2/grub.cfg
- Backup xorg.conf: sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf.backup
- Blacklist Nouveau: in grub.cfg or when you boot up the kernel edit the bootloader menu (press e) and add the following:
nouveau.modeset=0 rd.driver.blacklist=nouveau
- Blacklist Nouveau in modprobe.d (otherwise it may load in runlevel 3?)
cat /etc/modprobe.d/blacklist-nouveau.conf
insert this into the file with vim or something else:
blacklist nouveau

MP3 decoder
autoten (I haven’t tried this yet.)
yum install gstreamer-plugins-good gstreamer-plugins-bad gstreamer-plugins-ugly
To play DVDs you’ll need these codecs:
yum install libdvdread libdvdnav lsdvd
RPM Fusion Repository
First login as root, “sh”.
rpm -ivh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm
rpm -ivh http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm

If rpmfusion changes the url of these rpms though, download them to a directory (downloaddir) then otherwise use:
rpm -ivh downloaddir/rpmfusion-free-release-stable.noarch.rpm
rpm -ivh downloaddir/rpmfusion-nonfree-release-stable.noarch.rpm

Github homepage for gnome-shell-system-monitor-applet
You should be able to find it in Add/Remove Software

No tags

Greg Kroah-Hartmann, a leader in the linux community, visited my CS411 class last Friday, May 23rd.

He works for Novell in the SUSE Labs division, based out of Nurumberg, Germany. He said only one person works there in Germany while everyone else works around the world.

He explained how the hierarchy of the people who develop linux works. It’s very efficient because at some point a file will have been touched by at least two people.

Linus Torvalds and Andrew Morton used to pull the subsystem trees together by themselves, but now they use something better called Linux NEXT.

I asked him what kind of source control program was his favorite to which he replied, “git”.

There are some stagnated areas in the kernel development like PCMCIA and serial ports, but then again some older ports have been really active.

One thing I liked to hear was that he said, “The most linux kernel developers in the world are in Portland.” so I’m not too far away from some good innovators.

Greg on wikipedia

No tags

Another CS411 project finished! This time around we implemented an I/O scheduler for Linux. What is an I/O scheduler you may ask? Well, it simply manages requests usually from a block device (e.g. hard disk, media drive) and not a character device. An I/O scheduler needs to be fair and give a share of the disk bandwidth to each running process.

With SSTF, requests are serviced based on their proximity to the disk head, with requests closest to the disk head being serviced first. Requests are kept in a queue. The SSTF algorithm looks at the current disk head position and iterates through the queue looking for the request that is the shortest physical distance away. That request is the one that gets serviced next, and the process continues.

Is this the best I/O scheduling algorithm? No. I’m afraid not. If there is a request that was physically very far from the disk head it would possibly never get serviced. This dilemma is known as “starvation”.

More efficient algorithms use an “elevator” approach wheras the disk head moves along the disk surface picking up requests (people on different floors) and when it gets to the end of the disk (top floor) it can turn around and pick up more people (more requests).

We used the built-in linked list structure provided by linux. Many helpful functions were found in list.h.

Here is a good article that discusses changes in the 2.6 kernel from linuxjournal.com.

No tags

A recent project I completed in my Operating Systems II class was to improve the existing linux SLB memory allocator from first-fit to best-fit. The kernel currently gives 3 choices of allocators (SLAB, SLUB, and SLB). The SLB (Simple List Of Blocks) allocator, is designed to be a small and efficient allocation framework for use in small systems such as embedded systems. Unfortunately, a major limitation of the SLB allocator is that it suffers greatly from internal fragmentation.

There is a recent reply from Linus Torvalds himself on a Linux mailing list where he suggested the use of a best-fit algorithm.

The first-fit uses the first available space for memory. The best-fit algorithm my team implemented works by looping through the list of free pages until the first page found with enough free space. Then, we sort the list from smallest to largest free space. In this way the first space encountered by the algorithm will be the smallest space which fits the required amount available. Essentially, we are modifying the input to the algorithm to ensure better fragmentation rates and utilizing space on each page better.

There wasn’t a lot lines of code to add. It was a fairly simple hack, but I’m sure it could be even more efficient.
We compared the fragmentation from both algorithms and there was a definite difference.

The version of Linux we used was

No tags





No tags

Theme Design by devolux.nh2.me