avatar tianjara.net | blog icon Andrew Harvey's Blog

Entries tagged "linux".

I've switched to nouveau, an open source nvidia driver
7th March 2011

...and I'm back. I've finally upgraded from the nvidia proprietary driver, to the open source nouveau driver. After a little bit of time stuck at the console (I somehow managed to break X) trying to remember how to do things without a graphical display, I've got things working normal again.

First impression is compiz seems to be much slicker (ie. animations are smoother) on nouveau rather than the nvidia proprietary driver. I like it.

I had a couple of hiccups in the switch. I needed to clean /etc/X11/xorg.conf down to the 4 line minimal version to get a sane display resolution, and I needed to properly remove the nvidia proprietary driver (apt-get remove worked, but I needed to remove all the non-free nvidia packages). I also needed to install libgl1-mesa-dri-experimental to get direct rendering for compiz and basic OpenGL programs to work. Compiz seems to run fine now. The only noticeable difference in SuperTuxKart is a white flicker...

Tags: linux.
Trying to Recover From A Compiz Crash
29th August 2009

(Warning, I really have no idea what I'm talking about here, especially tty)

Yesterday Compiz crashed, probably seg faulted. I managed to restart it but then Cario (which Compiz was using) seg faulted. I ended up restart the X server. But just now Compiz crashed again. Most of the time when it crashes all is well it uses the default window manager without the flashy Compiz effects, but this time didn't, I couldn't move windows at all and there were no decorations. I could click launch icons on my top Gnome panel, but whenever I opened up a terminal I could not enter any text although I could still interact with it with the mouse (ie. use menu bars). I ended up (since my web browser was still displaying stuff) typing compiz into a text area in Firefox and selecting it, so I could middle click paste it. Then I created a custom application launcher in my Gnome panel, middle click pasted the command compiz and then I could click that one in the Gnome panel to start compiz again. All was fixed.

But there is something I still can't find the answer for. I tried going into a different tty using Ctrl+Alt+F1, but trying to run compiz in tty1 failed because it was "unable to open display """ and also "no xterm found". What I wanted to do was start a process in tty1 for tty7. I have no clue how to do that. Any ideas? I endeavour to learn more about the X Window System. Oh and if all else failed I could have restarted the X server, but then I loose a lot of stuff in RAM (such as things I haven't saved).

Tags: linux, ubuntu.
Very Useful Ubuntu/Unix Commands
29th June 2009

Just some Ubuntu/Unix commands that I seem to find very useful but can be hard to remember at times.

PDF Concatenation

pdftk in1.pdf in2.pdf cat output out1.pdf

Its annoying that nautilus doesn't integrate this by default, so I could select some PDF's then right click and choose merge. Luckily I can do this with the fairly simple Nautilus Actions Configuration app. But this takes time and the average user doesn't have the time to research these things on how to do it themselves. Of course this could be extended further to match what you can do from the command line, such as choose some method of ordering the files, or choose to do weird things such as rotate every second page. Sure you want to keep things simple, so as a start it would be great to see something basic. There are probably even nautilus scripts in the repositories out there that do this exact thing, but you spend half your time finding them and installing them. I think this should be enabled by default, or put in some options page somewhere.

Truncate an mp3 file

mpgsplit input.mp3 [00:00:20-00:00:58] -o output.mp3

It appears that this doesn't re-encode so it seems to run very fast.

Mount an ISO

sudo mount -o loop ~/disk.iso /media/cdrom0

Strip audio from a video file

ffmpeg -ab 320k -i in.mov outaudio.mp3

Unfortunately when I left out the bit rate, it defaulted to 14K or something much lower than what the source file was using.

Search all files in the current directory for some string

find . -exec grep "searchthisstring" '{}' \; -print
find . -exec grep -q "searchthisstring" '{}' \; -print

Trim and nup pdfs

pdfnup --nup 2x2 --pages 26-140 --trim "1cm 1cm 1cm 1cm" infile.pdf

Wake from Suspend

sudo rtcwake -u -s 12600 -m on

... then you need to manually put the computer in suspend and 12600 seconds later the computer will resume.

Susped

pm-suspend

Shutdown

sudo shutdown -h now sudo shutdown -r now

... the -h means halt (shutdown), -r means reboot.

Tar and Gz all the files in a directory

tar -cvfz file.tar.gz *

Get file info from an HTTP server without downloading

wget -S --spider http://www.site.com/file
Tags: computing, linux.
An old memory of Linux
13th March 2009

I only started using Linux when I started Uni (2008). I knew nothing about it prior to this. I had heard of it but that is all. I now wish I'd become aware of it sooner but then I realised I had the chance. A friend of mine introduced me to it in year 10 (2005) and I even got an Ubuntu 4, 5 or 6 CD (I can't recall which one). But I never used it. Why not? Well, it occurred to me that Windows was the sole reason for me not at least testing Linux out. I had had some bad experiences with some Windows operating systems and installing windows operating systems. So I had the thought "I don't want to risk breaking my computer/loosing things again with another OS install" just to test this Linux thing out. Huge mistake! Though at least I've learnt from this experience and I'm trying to try things out and give them ago before I just assume them to be poorer quality or choosing not to use them.

One of the best pieces of advice that I would give is to try new things out, if you don't try it you won't know what your missing. For if I was always too afraid to try new things out I would still be using Windows 95.

Tags: computing, linux.

RSS Feed