Archive for the ‘Uncategorized’ Category

Arch Linux – Software Rasterizer fix

Saturday, April 17th, 2010

I just wrestled with Arch Linux for several hours before figuring out a stupid mistake.

If the output of glxinfo | grep -i rend includes Software Rasterizer but already has direct rendering: Yes, then it’s very likely that you simply didn’t add your user to the video group. Do so by running usermod -a -G video [username] as root (or with sudo). After logging out and back in (or maybe a reboot), the output should now include Mesa and your video should be running fullspeed.

I also recommend undoing whatever changes you might have made from the ATI page and then going through them again, after you add yourself to the video group. For example I was messing with early and late KMS start but after adding myself to the video group I removed that; I basically undid all my changes, leaving only my custom xorg.conf file, and the video group was indeed the cause of all of my issues.

However, you may want/need to install radeon_ucode and maybe radeon-initrd still despite the video group. Do a search for installing packages from AUR, and follow the simple steps to get those installed in your system, and they will take effect on the next reboot. After radeon_ucode is successfully installed, dmesg | grep firmware should say something like “platform radeon_cp.0: firmware: requesting radeon/R300_cp.bin”; and the last line of dmesg | grep radeon should tell you that it initialized radeon. In any case, I installed those packages and left them in after discovering the video group, and my card is working great. So I don’t think they hurt anything.

Ugh. I can see the use in this feature for a multi-user system, but at the same time, it’s a little annoying that the Beginners’ Guide wasn’t very clear about it and the ATI page had nothing about it. I guess the moral of this story is, debug things as root first; the root user would’ve run video at full speed and then I may have narrowed it down from there.

Also a little sidenote: don’t use glxgears as a benchmark; the FPS can vary widely depending on the size of the window. For a moment I thought xmonad was slowing down my graphics compared to xterm, but instead I was just getting lower glxgears FPS in xmonad because it rendered on the entire left half of the screen, whereas xterm opened glxgears in a tiny window up in the corner of the screen. False alarm! :)

Artifactory in CentOS

Saturday, March 13th, 2010

Whew, I just had quite a difficult time getting Artifactory to install and run in CentOS. They have a nice installation guide, and it almost worked but not quite.

I am using the JPackage repository, so my java installation probably came out of there. And it seems to be slightly nonstandard, so I had to find the correct paths to make Artifactory happy.

Oh and also, I’m using the standalone Artifactory. I think it’s high time for me to learn an application server but for now, this is the last piece of my setup so I’ll let it be. Those of you that have the slightest clue about application servers might want to stop right here and just drop the Artifactory war file in your server.

Anyway, I’ll get to the point. Here’s what to do:

  • Unzip artifactory somewhere. I unzipped it inside /usr/local; so, my ARTIFACTORY_HOME = “/usr/local/artifactory”.
  • su and cd to that directory, then run ./bin/install.sh
  • cd etc (or /etc/artifactory, but not /etc; install.sh creates a symlink in $ARTIFACTORY_HOME/etc that points to /etc/artifactory)
  • Now edit the file ‘default’ with your favorite editor (vim default).
  • Uncomment or add the two lines:
  • export JAVA_HOME=/usr
  • export JAVA=/bin/java
  • Save and close this file. Now /sbin/service artifactory start – and you should be good to go!
  • Optionally, before starting (or do a restart afterwards), edit jetty.xml inside the etc directory and customize the port that Jetty runs on, on line 52.

Feel free to comment below if you found this useful or if you have anything else to add!

Windows 7: Skype in Taskbar fix

Wednesday, March 10th, 2010

Edit: Here is the proper way to fix this problem:

  1. start skype
  2. go to tools –> options –> advanced.
  3. uncheck Keep Skype in the taskbar while I’m signed in.
  4. click OK

Thanks to “Good Samaritan” for pointing this out in the comments.


Here’s a quick and easy fix to the problem of Skype on Windows 7 staying in the taskbar instead of minimizing to system tray.

1. Exit or quit from Skype program.
2. Right click on Skype icon on Desktop or Skype shortcut in Start Menu, and select Properties.
3. Go to Compatibility tab.
4. Under “Compatibility Mode’ section, check the checkbox for Run this program in compatibility mode for: option.
5. In the below drop-down box, select Windows Vista (Service Pack 2).
6. Click OK.
7. Start the Skype program, and now it should minimize to system tray.

These instructions were found at http://www.mydigitallife.info/2010/01/23/how-to-minimize-skype-to-windows-7-system-tray-notification-area/comment-page-1/.

Wubi kernel upgrade goes to sh:grub prompt

Friday, February 26th, 2010

Edit: Welcome those of you who just upgraded to Linux kernel 2.6.31-20! This page WILL help you fix the sh:grub problem! :)


I’m running Wubi with Ubuntu 9.10; I upgraded my kernel (from 14 to 19) and after a restart, landed at the GRUB prompt, “sh:grub>”. Yikes! I wasn’t actually familiar with the GRUB prompt before now. After some Google searching, here’s what I found: (keep reading, this is not the final solution, don’t bother following this link unless you’re just curious)

sh:grub Fix Wubi after grub-pc update on Karmic Koala

I followed those steps. He is very complete in his instructions. However, when I hit the “boot” command after loading up the 19 kernel, my computer just rebooted. I tried it again with my version 14 kernel and it booted into Ubuntu just fine. Okay, so I figured I’d just uninstall kernel 19 and go back to 14. Well, when I tried to do that in Synaptic, the generic meta packages depend on 19 so they would have been removed as well. I don’t know if this is a bad thing, but it scared me into more searching, where I found the real solution:

Boot Problems:Wubi 9.10

It’s quite simple; just do as the Solution section on the page says. I was careful to back up my existing wubildr file, but after rebooting, my boot menu was back! I chose kernel 19, and it booted correctly. Yay!

Oddly enough, if you do a Google search for “boot problems:wubi 9.10″ or even include site:sourceforge.net, you will not find that page above. Edit: it is now in Google, though what search terms bring it to the top of the results I can’t be sure.


Edit 3-5-2010:

I just upgraded from 2.6.31-19 to 2.6.31-20 without problem. I did not have to recopy the wubildr file or anything; it just booted correctly. So it looks like this is a permanent fix!

MSS.log is locked

Sunday, February 7th, 2010

“C:\ProgramData\Microsoft\Search\Data\Applications\Windows\MSS.log”

Why is this MSS.log file locked? Is your backup program stumbling over it? Maybe you get this error:

The process cannot access the file because it is being
used by another process.

(more…)

Recursively delete directories from FTP

Sunday, December 20th, 2009

Our web system at work is a little bit of a mess. We have a test server, but we don’t actually use it; we have Subversion, but, well, I don’t use it. There’s no enforcing mechanism to keep the SVN files and FTP in-sync and clean, so there are files on the site that aren’t in SVN. Unfortunately though, I need to use it; it keeps our changes in sync so that we don’t write over each other. The test server can be set up later.

Anyway, somehow some of the .svn folders got uploaded to FTP. There was a good 30 or so of them, scattered in subdirectories. And we’re talking a huge website; 6+ GB of content, I don’t even know how many folders, some of them run 5 or 6 deep. I needed to find all of the .svn folders and delete them.

I wrote a Python script to do it. I’m quite opposed to using Python as anything serious (I wouldn’t write an application in it) but I love how quick it is to whip up a little tool.

I think the following code is self explanatory, at least for someone who knows Python. You may need to obtain ftplib; I can’t remember. Of course, this code can work for any directory name that needs to be recursively found and deleted; just replace ‘.svn’ on the sixth line, and optionally change the output on the seventh; and, regardless of the directory name, you need to change the FTP server location and user/pass at the bottom of the script to point to your own FTP server.

Enjoy! (click ‘Read the rest of this entry’ to see the source code)
(more…)

Honesty (with yourself) is the Best Policy

Thursday, August 13th, 2009

Over the last few years I’ve done a lot of what I like to consider “meta-thinking” – thinking about myself, and my life, and trying to figure out how to make it better. I went from being a B/B+ student in high school (granted, in the IB program) to a 4.0 in Spring semester. I went from scrambling to get homework done in the parking lot before school, to doing it several days in advance in the library, and doing it right. I studied for exams. Basically, I took school seriously.
(more…)

My thoughts on the banning of Microsoft Word

Wednesday, August 12th, 2009

Today, Microsoft has been banned from selling its Microsoft Word product in the US.

My first thoughts are, have the stores been told? Is Microsoft Office being pulled off the shelves? How can something like this even happen? In fact, I think the judge and the court and the entire state of Texas should be banned from Microsoft Word. If I were in charge at MS, I would issue an immediate Microsoft Update to revoke all licenses of MS Word and prevent people from opening it. What kind of widespread panic would ensue? Maybe then the court would take its decision back.

i4i is a company that apparently helps companies manage, collaborate on, and update important documents. These documents are in a .xml format which is meant to be opened in Microsoft Word. So they are deeply tied to MS Word in the first place. Why they would want to send it off the shelves is beyond me. They even tout, in their (PowerPoint) presentation linked to from their site, that they have a “Word-based XML Authoring” tool.

They have a press release on their site regarding this patent infringement mess. In it, they tout the $200 million (!!) that Microsoft will be giving them, for “damages” (oh yes, all the damages from them piggybacking off of MS software for their own product). They cite patent 5,787,449.

Here’s the patent. But don’t worry, I read through most of it and I’ll summarize it for you.

In the past, formatted documents have contained their formatting within the document. For example, HTML looks like this:

Here is some <b>bold</b> and some <i>italic</i> text.

And it would result in:

Here is some bold and some italic text.

Well they came up with this process where you separate the text from the formatting. You have a map that says which characters are formatted which way. Then the software can display formatted text from this map, instead of reading special markup tags in the body of the text. MAPS ARE NOT A NEW CONCEPT. This is NOT a big deal! Even at its time, filed in 1994 and issued in 1998, I really cannot believe that the patent office passed this.

This is not an invention. They took two Legos, put them together and said “here patent office, give me the right to sue anyone that puts two Legos together.” And so now, that’s exactly what they did.

Back when the internet was new, people were buying up domain names for the sake of extortion. You’d buy a good name, like the name of a company, for about $10 (for one year). Then you’d go to the company and say “hey guys, I bought your domain name so it’s mine. But you can have it if you pay me!” That’s the same sort of thing that happened here, and now Microsoft has to pay giant sums of money because they happened upon the same mechanism but it was patented.

Who ever came up with the idea of patenting mathematical structures anyway? Can I place a patent on, oh I don’t know, a mathematical matrix with letters in it instead of numbers, then go around suing algebra teachers? Another example of the ridiculousness of this case.

I am completely against the idea of patenting simple software concepts like this. The problem, of course, is what constitutes “simple.” Maybe back in 1994 this was a novel concept. Or maybe there were other people using the same simple concept and i4i was the first to send it to the patent office.

Anyway this has turned into a ramble/rant so I’m just going to cut this entry here. I’d like to hear your perspective, so please leave a comment. Let me know what you think, if I’ve gotten anything wrong or if there’s any misinformation. One bit of info that I’m unsure about is really whether Microsoft has been banned from selling Word. That’s what the news article says, but i4i’s announcement says “i4i can seek a court order blocking further use of its invention by Microsoft.” I can’t find the official court thing online to read the real verdict.

All My Base Are Belong To Microsoft

Monday, August 3rd, 2009

I just finished with today’s Microsoft Student Partner training, all about Facebook, Twitter, and blogging and basically using these social networking platforms to broadcast Microsoft news and events.

My blog here has been set up for a while but as you can see from the posts before this one, I haven’t done a good job. Today begins a new era of this blog. From this day forward, I will actually write in this blog.

The title of this post was tongue-in-cheek. I am not completely devoted to Microsoft. Yes, I am hired as a Microsoft Student Partner, and yes this will be my blog from the standpoint of me as a Student Partner as well as me as a student. So whether you like it or not, you will find plenty of content here about new Microsoft things. But they will all be very exciting, I promise! Gone are the days of blue screens of death and 10-minute boot times. Microsoft is doing some very cool things across the board and I fully intend to give my honest opinion and recommend only the best.

I use Windows 7. I have an Apple iPod Touch. I keep up with the Linux Users’ Group mailing list and club events. I’m very diverse when it comes to technology. Why? I’m a computer science student, and computer science is not about what operating system you use, it’s about the computers. Underneath it all, these sparring operating systems and companies are joined by one thing: they operate computers. They compute. They think in binary, they have memory, processors and storage of some kind, and they can be programmed.

My programming language of choice is Java. I like it for many reasons, but this is one of them. Whether I choose to use Windows, Linux, or Mac, I can write Java. It’s a universal language. My code will (or should) run on any operating system. I really like that. (Okay, so I also really like C#/XNA, which of course is Microsoft-only)

Anyway, this is the first of (hopefully) many posts to come. I’ve got a lot to say, and I’ll say it all here. Stay tuned.

Testing Ubuntu blog posts

Tuesday, March 31st, 2009

I just added the gnome-blog applet to my Ubuntu install, so this is a test that it’s working.

By the way, since I haven’t mentioned it here, I’m now using Ubuntu almost full-time.

I do need Vista for certain things though, such as XNA, so I plan to set up a dual boot on my 320gb drive pretty soon… Whenever I get time. Maybe this Saturday at the Linux Installfest…