Sunday, February 19, 2012

Open Graphics Drivers

So this is my first post in this How-To section. In this post I just wanted to go over a small driver situation I went through just recently. For everyone out there who runs open source (Linux) and also has an Nvidia graphics card, you have probably heard of the Nouveau driver. Nouveau is the default open source driver used on most Nvidia cards. It is possible to follow a lengthy procedure to switch to the proprietary drivers from Nvidia and there are things that can go wrong during that process. In this how to, I'm going to cover one of those possible issues and what I did to get through it for OpenSUSE 12.1 x86 64bit and a Nvidia GeForce 9800GT card.

The instructions were rather simple to follow. Just open a terminal, become root and run a script to verify your graphics card. After verifying what card you have to determine what driver you'll need, use zypper to to open the 11.4 repositories and download the driver. The instructions then say to simply reboot your system and that is it. Well I'm here to say that I think a step is missing here because it wasn't quite that easy for me. Maybe those instructions were just a bit too simple?

When I reboot my computer, my default GUI wouldn't load and I ended up with only the CLI screen. I did a Ctrl+Alt+Del from here and tried again. Yep, same thing, no initialization into the GUI. This is when it's nice to have other computers in the house. I turned on the laptop and Googled “OpenSUSE won't initialize” and found the instructions I needed. Remember, these instructions are based on how I did it. Not that this is necessarily the right way, but it worked for me so I thought I would share it so maybe it could work for someone else.

I initialized another reboot and this time interrupted the process, similar to if someone were going to go into BIOS, and selected Failsafe Mode. This is of course the reduced graphics and minimal driver installs just to do very basic repairs when things go awry. Once I saw that small fraction of my desktop come up, I managed to work my way over to YaST and get into the boot loader options.


This area is where we configure what profile the OS is going to boot into. Say for instance, we wanted to change what turns on and what doesn't at boot. This is the area where the administrator goes to do that. We can set various sets of different profiles depending on what we want to do or don't want to do. In this particular case I wanted to switch the default boot profile from Desktop to Default. The Default kernel is optimized for running a server such as if I used my LAMP stack for more than just web design  and development testing. Desktop is a copy of the Default kernel but optimized for desktop usage that is used on a day to day basis so that if something does go wrong, like it did for me, we can always fall back to the Default desktop and copy it over to Desktop again deleting the old files.


In picture number two above, we see what gets initialized during boot for any given profile. Once someone has switched to the Default profile as the the default loader as done in the control panel shown in picture number one, there should load a GUI with a resolution that can actually be worked with. Go into YaST again and go into Boot Loader and then into Manager. In this screen we see where the boot files are kept and what we need to do to copy all the relevant data from Default into Desktop then rename it Desktop. Later we can go back and rebuild the desktop profile correctly, but for now we just want something to run on without it being the only good profile available just in case again. Once the old Desktop profile has been replaced with the Default profile boot configuration, then it's just a matter of going into the actual boot file and copying and renaming.


In picture number three above is just an idea of where someone is going to find the boot file with the data we are going to have to work with. This is the root file structure where everything starts for our Linux system. It's fairly easy to navigate once a person gets used to working with it. I hear people at the University I attend call Linux a CLI operating system. I suppose when set up for basic server operations it could be, but I have gone through the route of learning grep and it's kind of a pain in the butt. It is very similar to the old days of having to navigate a computer. A lot of cd/ or /.. or li and all those goofy commands instead of drag and drop and navigating around with a GUI.


Picture number four above shows the boot file system. What we want to do here is of course make copies of everything and set them aside just in case. A flash drive or external drive or something not on the same hard disk as the original OS runs from. Once copies are made, what I did was to delete each file that had -desktop in it and replace it with a copy of the default file renamed to the same as the original desktop file. Now like I said before, this may or may not be the right way of doing this but, this is the way I did it in a pinch and it's been a few weeks and I'm still running good. Yes, the proprietary drivers did end up being installed.



If these instructions work for someone else or helps them out that's great! That's the fun in sharing experiences and writing these How-To's. If someone does find themselves in this situation and does get it running again, make sure to report your experience to the people over at OpenSUSE and get their feed back. There are teams of really cool people there who are all volunteers and provide support better than most paid services would. I have yet to drop this scenario of what I did on them but, when I do I will update this post with their thoughts and comments. In the meantime...

Happy safe computing! 




Tuesday, February 7, 2012

Welcome

Welcome to the new How-To section of ROGUEHORSE.com. I thought it would be a good idea to section out the articles I write on how to do things from the articles covering random tech news and information.

Just like the new "Just Me" blog, I'm not sure how this is going to go or even how long it will last. Just like anything else though, right now just think of it as an idea in beta.