Archive

Archive for the ‘Linux’ Category

Google Ireland Search Plugin for Firefox

July 1st, 2010 No comments

I was pretty irritated with the Google Search in Firefox constantly directing me to Google.com as opposed to Google.ie. When I search with Google.ie the results are better targeted to Irish people are therefore more useful to me. So as a result I wrote my own Google.ie Firefox search.

If you want to use it click here to install.

Make a Static Page your Home Page in WordPress

June 17th, 2010 4 comments

I’ve been doing a couple of sites for a Friend of mine who also happens to be my MMA instructor. RebelMMA and KenHealyFitness. They aren’t so much blogs as advertising websites. As a result I wanted to make the static pages jump out, whereas the blogging function should be hidden a little further into the site. I still wanted to use WordPress though as it’s already running on my server. So I had a dig around and found it was actually easy to move the blog away from the front page. Now on those sites when you vist them you get a static front page and you have to navigate to the blog.

Check out the steps on the WordPress site.

Categories: Blog, Linux Tags: , , ,

bin/bash^M: bad interpreter: no such file or directory

December 29th, 2009 4 comments

I got this error recently when trying to execute a bash script in Linux.

bin/bash^M: bad interpreter: no such file or directory

The problem turned out to be the fact that I downloaded it to a windows machine before copying it to the Linux box. When I downloaded it windows added a number of Windows Carriage Returns at the end of each line. Why? Don’t ask me!

After a bit of Googling I found a number of posts that recommended I use dos2unix to convert it into unix file format. Unfortunately I didn’t have this on my system. So instead I used the following command.

tr -d '\r' < inputfile > outputfile

Categories: Linux, VMware Tags:

Upgrade Free from Vista to Windows 7

October 23rd, 2009 1 comment

If you bought a laptop or desktop from Dell Ireland at any stage you might be eligible for a free upgrade to Windwos 7 which is supposed to be way better.

Check out the dell website for more details.

Of course i would recommend installing Kubuntu on your Dell system :-)

Categories: Linux, Opinion Tags:

Install the “old” amarok 1.4 in KDE 4

May 15th, 2009 No comments

amarok_wolfI installed KDE4.2.2 recently. I used KDE4.1 for about 5 minutes but uninstalled it because it was very slow, couldn’t do half of what KDE3 seemed to be able to do and was very frustrating. The 4.2.2 release is much nicer. Very polished and stable.

Unfortunately my favourite Linux Application amaroK has been butchered in KDE4. The playlist is shoved to the right and isn’t as intuitive as it groups albums together in a seeming random way. There is a huge panel in the middle that just shows the cover and on the left there are a few menus. Also it doesn’t detect my iPod, or at least I can’t figure out how to drag music into the iPod.

As a result I decided to keep KDE4 but uninstall amaroK2 and install amaroK1. Since I use Kubuntu I had to look for how to do it in Ubuntu. After a bit of googling I found the ubuntu-blog which showed me how to do it. I have pasted the instructions below.

  1. echo -e “\n## amarok 1.4 \ndeb http://ppa.launchpad.net/bogdanb/ppa/ubuntu jaunty main\ndeb-src http://ppa.launchpad.net/bogdanb/ppa/ubuntu jaunty main” | sudo tee -a /etc/apt/sources.list
  2. sudo apt-get update
  3. sudo apt-get install amarok14
Categories: Linux Tags:

Use an SSH proxy to access the internet around a firewall

May 7th, 2009 No comments

I was using an ESX Server as an SSH tunnel to access the webpage of one of my VMs that was on a different network than my laptop today and I thought it might be useful for people.  Particularity if you want to set up a proxy server to access the internet via a Linux system you might have running outside of your corporate firewall. This would be very useful to access sites that are blocked by your company or use it to download bittorrents etc.

What you need is

  • A Linux system on the internet (running at home, a cheap VM (like this site is running on rapidvps.com, or maybe one running on VMware Workstation at home), or maybe your home router)
  • Putty (or a console shell if using Linux)
  • A Web Browser (or any application you want to access the internet, like bittorrent or whatever).

Windows:

  1. First you need to have SSH access to your Linux system. Not necessarily root.
  2. Use Putty to create a connection to your system. But before you connect look at the options on the left.
  3. Select SSH > Tunnels
  4. Here enter a source port of 1080 and select the Dynamic Radio button.
  5. Select add.tunnelport
  6. Next open your session to your linux system
  7. Configure your application to use a Socks proxy over port 1080. For example in Firefox  select Tools > Options > Advanced > Network > Settings and configure it to use a SOCKS proxy as below.

Linux:

  1. First you need to have SSH access to your Linux system. Not necessarily root.
  2. Open an SSH session to your system using the following syntax ssh -D 1080 user@mylinux
  3. Configure your application to use a Socks proxy over port 1080. For example in Firefox select Tools > Options > Advanced > Network > Settings and configure it to use a SOCKS proxy as below.

firefox

X Forwarding:

Also Linux has a cool feature called X Forwarding. If you open a session to a Linux server from a Linux server (or using a program like Exceed in Windows) using the X flag i.e. ssh -X user@mylinux then you can simply open the GUI of the web browser on the remote machine. I use this for bittorrent.

For example there is not much use in proxying bittorroent to my machine in work. I’d mush rather have it downloaded at home. So I ssh -X to my server at home. Run the command ktorrent & and hey presto the Ktorrent GUI opens on my machine in work, but is running at home. So anything I download will be saved at home. Cool eh?

Categories: Linux, VMware Tags:

Images missing after moving WordPress folder

April 29th, 2009 No comments

wpfordummiesI have a few websites running in this server. One of them is the Riverside Crew MCC site my brother runs. I moved it from one folder to the other on my server. When I did a lot of the images no longer worked. It turns out that you need to manually specify the folder that stores images in wordpress. Since I moved all of the blog to a new folder that location no longer existed. So obviously I updated the location in Settings > Miscellaneous (Not Settings > Media as you would expect). However that didn’t work either.

Looking at the links where the images used to be I can see that it still points to the old location. So it looks like when you change that settings it is for any images you are going to upoad. It doesn’t update old links. After a bit of Googling a figured out that you will have to update each link in the database individually. It explains how this is achieved on the WordPress site.

However I found an easier solution. I simply created a shortcut in the old location pointing to the new location. For example I moved the wp-contents/images folder from /var/www/html/site/wp-content/images to /var/www/html/site/blog/wp-content/images. So all I needed to do was create a link in the old location pointing to the new location. Once that was done everything worked fine again. Without having to mess around in the database!

First I recreated the wp-content folder in the old location

mkdir /var/www/html/site/wp-content

Then I changed to this directory

cd /var/www/html/site/wp-content

Then I created the link to the new images folder

ln -s  /var/www.html/site/blog/wp-content/images images

And voilá!

Categories: Blog, Linux Tags:

Disabled Pop Up Image

October 14th, 2008 No comments

I had to disable the pop up images on the main page as they were messing with Internet Explorer. Every time you tried to access the main page you got an error saying that Internet Explorer could not open the page. Even though it clearly opened in the background. I am not sure why that happened as it works fine in the Gallery section and also in Firefox, Opera etc.

I think there is a patch out there to fix IE but I can’t really expect everyone to install that just to view my site. So I’ve disabled pop up images. Which is a pity because I really liked them. Ah well, maybe if I can spend a little time looking into it I might find a workaround.

Anyway to all you IE users, welcome back (and use Firefox!) :) Sorry it took so long for me to discover that there was a problem but I use Linux.

After a little looking around I found a Microsoft IE Bug explaining the issue. It looks like it’s an issue with putting the Java script in a Div container.Unfortunately I use them to display entries (such as this one) so that’s not easy to workaround.

Categories: Blog, Linux Tags:

Success M1530

April 18th, 2008 6 comments

KUbuntu LogoJust got all of my hardware working on my new laptop under KUbuntu,  fingerprint reader logins, Webcam, sound, media buttons, remote control, microphone everything. Also stopped the dreaded media button from overwriting Grub everytime it’s pressed.

I am disappointed that the sepakers and the microphone on the laptop are such terrible quality, especially for a “multimedia” laptop.

I’ll post the steps I took to get everything working as soon as possible. But when KUbuntu comes out in a few days with KDE4 I don’t know how much will be relevant. Maybe I’ll just wait until then.

Categories: Linux Tags:

New Laptop

April 9th, 2008 7 comments

Got my new laptop today! A very shiny Dell XPS M1530. It looks good so far. Click here for a good look at it.

It came with Vista (yuck) pre-installed. Seems wicked fast so far. The only thing I am still trying to get the hand of is the finger print reader. It doesn’t like me. Oh and it has no modem so when I am back in Millstreet it looks like surfing the net is out of the questions.

I think I am going to leave Vista on a partition so I can play games and maybe use some of the Media Centre functions but as all of my Music and Videos are going to be in a soon to be install KUbuntu partition I don’t know how useful that is going to be. Maybe there is a way Vista can read ext3 so I can use them. We’ll see.

I am going to install KUbuntu on it soon and I’ll update the blog with any issues I have in the hope it may help someone else.

Categories: Linux Tags: