Wednesday, July 2, 2008

Fixing rdp MIME type in Ubuntu Linux

If you've ever been presented with the problem of downloading a dynamically generated (or even static) rdp (Remote Desktop) file from within Firefox in Linux and you were optimistically expecting Firefox to recognize it and open it in some graphical interface like tsclient, you were probably sorely disappointed - you might have gotten a message like -

You have chosen to open
example.rdp
Which is a: BIN file

In this instance, you are only granted the option to Save the file to your computer.

To fix this, you need to configure Linux to automatically recognize this MIME type so that Firefox recognizes the file type as something besides binary (for some reason you can't directly add the recognition in Firefox without extensions).

To do this, you need to add the rdp MIME info into the file /etc/mime.types. Run the following two commands to quickly achieve this -

sudo -i
echo "application/x-rdp rdp" >> /etc/mime.types

This simply appends the rdp MIME info to the file.

Trying download a rdp file from Firefox now (you don't need to restart it). When the Save dialog pops up (and actually recongnizes the file type!), press the "Browse..." button to open the Application Helper selection dialog.

In the resulting window, locate the "Location" bar and type /usr/bin/tsclient (for example, if you have this installed). Press "Open" to continue. Firefox should now associate .rdp files with tsclient. Press "OK" on the open dialog to proceed.

The Terminal Services Client GUI will open. You may wish to change the various options using the tabular interface provided. This application is richer than the built in Windows Terminal Services client itself!

The next time you click on a n RDP file, Firefox should remember the association and ask you if you want to open the file in tsclient. If the "Open with" field in Firefox's Open dialog on attempts subsequent to this tutorial is blank, press "OK" regardless. tsclient should still launch.

Side note: to use tsclient, you need the packages

* tsclient
* rdesktop

So just

sudo apt-get install rdesktop tsclient

9 comments:

Anonymous said...

you have a nice site. thanks for sharing this enormous resources. keep it up. anyway, various kinds of ebooks are available here

http://feboook.blogspot.com

Anonymous said...

Genial fill someone in on and this enter helped me alot in my college assignement. Say thank you you for your information.

Anonymous said...

Perfect solution. Thanks

buy generic cialis online said...

Well worth to read this article, thanks for sharing this information. With this article you offered me got a chance to know about this, anyway i say Great Article! and waiting for you next article about this interesting subject.

Ryan said...

Anyway on how to do this for firefox in windows XP?? =)

viagra online said...

I was always told that Linux was the best OS available on market, so I asked my cousing Robing to get it installed on my PC. Dude, that thing was really hard to understand, I think it might be very secure and all, but that thing man is really complicated. Not user friendly.

airbnb clone said...

Great! It was very interesting and meaningful. Keep posting. I follow you.
PHP Scripts| Angry birds flash| Angry birds flash| airbnb clone|

Unknown said...

Daily update news about Real Estate in Vietnam

how to increase sperm count said...

increase your semen count, volume - pill sperm volume and herb increase natural semen using volume.