Molly-guard to save the day

If you have one or multiple boxes running somewhere at a remote location and you manage them trough ssh, you’re possibly familiar with the following situation.
It has been a long night.
On your desktop there are multiple terminals gaping in the dark.
During the whole night, some of these dark ships transported you to far remote playgrounds and back.
The other  ones were mere destined for local hocus-pocus.
But it’s time to call it a day and go to bed.
You fire away the ‘poweroff’ command just to realize a fraction of a second later that this was the window to your homebrew webserver…

But it’s too late.
The connection is lost and the machine has no wake on lan…
Now you have to get out of your chair, find those damned pants and go all the way up to the attic to switch it back on.

No one likes this horrible situation. So Molly-guard is here to save the day.
Molly-guard is is a bunch of scripts that capture the halt, reboot, shutdown and poweroff  commands and give you a second chance.
By checking if the tty has been created by sshd, it checks whether you’re logged on from a remote machine.
If that’s the case, molly asks you the hostname of the machine you want to shut down.
If the hostname you entered does not match the hostname where Molly is running on, you’re saved 🙂

You might think this is a silly tool, but after a long time of silence, I’m back to using my home server and just saw this screen:

A little cool thing to know:

A shield to prevent tripping of some Big Red Switch by clumsy or ignorant hands. Originally used of the plexiglass covers improvised for the BRS on an IBM 4341 after a programmer’s toddler daughter (named Molly) frobbed it twice in one day. Later generalized to covers over stop/reset switches on disk drives and networking equipment. In hardware catalogues, you’ll see the much less interesting description “guarded button”.

— http://www.catb.org/~esr/jargon/html/M/molly-guard.html

Molly-guard man page from ubuntu: here

Who’s there? – Invalid ssh user

So, It’s been a while since I’ve set up my home server to use it as a swiss army knife at home and on the road.
Now I was wondering on the system’s integrity.
First step was checking /var/log/auth.log
To do some quick’n’dirty check I’ve ran the following command

grep “Invalid user” /var/log/auth.log | less

Continue reading Who’s there? – Invalid ssh user

Twirssi error: Timestamp out of bounds

I just found my twirssi inactive. 
When loading the script and authenticating with oath enabled, I got the error:

-!- Irssi: Error in script twirssi:
Timestamp out of bounds

This is (most likely) the result of a wrong system date/time.
Quite easy to solve, just sync it to an NTP server.
Open a terminal and enter:

ntpdate pool.ntp.org

Try to load the script again and login.
All should be fine now.

Wrong time in Windows on Dual Boot system.

When you have a dual boot with Windows and Ubuntu you might experience some time travelling when rebooting to windows.
To solve this, simply boot into Ubuntu and edit the /etc/default/rcS file as sudo and change the UTC value from yes to no.
It should look like this

TMPTIME=0
SULOGIN=no
DELAYLOGIN=no
UTC=no #Set according to your system (BIOS) clock.
VERBOSE=no
EDITMOTD=yes
FSCKFIX=no

These values are being used by the scripts at /etc/rcS.d/ that get invoked during boot (even in single user mode)

To be clear, this is not an Ubuntu error. It is simply the Windows that never assumes the system-clock to be in UTC.

If you wish to adjust this in the Windows installation execute regedit and navigate to:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation

Change the RealTimeIsUniversal value to 1.

If you’re simply looking for a wach to change your hardwareclock on linux you can check my other article on Changing date and/or time on Linux.

How to split flash (.flv) file to upload to youtube

Say, you have a huge flv flash file you want to upload to youtube.
You’ll find yourself in trouble as there is a limit to the filesize you can upload.
Where you needed to download and install bloatware in Windows to accomplish this,
it’s super easy in Linux.

ffmpeg will do the trick.
Say you want to cut the flash movie in pieces of 10 minutes, you can do this like this:

ffmpeg -i filename.flv -ss "00:00:00" -t "00:10:00" filename_chunk.flv
ffmpeg -i filename.flv -ss "00:10:00" -t "00:20:00" filename_chunk2.flv
ffmpeg -i filename.flv -ss "00:20:00" -t "00:30:00" filename_chunk3.flv
...

Now you’re ready to upload your video’s.

Ubuntu 10.10 and ATI Radeon HD 6870

So, quite some time ago I made the mistake of buying the ATI Radeon HD 6870 without first checking if it would play nice with my Ubuntu 10.10 desktop.
Turned out it didn’t 🙁

But now, there are proprietary Linux drivers released by ATI/AMD

  1. First, you should update your system (just to be sure).

    sudo apt-get update
    sudo apt-get upgrade

  2. If you’ve been using older drivers, remove them.

    sudo apt-get remove –purge xserver-xorg-video-radeon

  3. Download the install package from the AMD suppot pages and make it executable

    chmod +x ati-driver-installer*.run

  4. Run the installer as sudo-user

    sudo ./ati-driver-installer*.run

  5. Reboot

Enjoy!

The Linux 2.6.38 kernel carries the ATI Radeon HD 6000 open source support. (just fyi!)
If you encounter problems or found this post helpful, it would be nice to leave a comment below.
This way, I can adjust it to the needs of my readers.

Nasty little OpenSSH Bug

So I’ve been using my Targa NT9231 as a home sever (Running Ubuntu 10.10 server edition) for a while now.
It’s been serving several purposes such as internal webserver, irssi, monitoring and tunneling/proxy server.

As all wise people should do, I’ve been using OpenSSH to connect to it.
Solely  connected to it from my netbook, as my desktop Ubuntu computer died after the purchase of a new ATI (curse you) Graphics card.
But now, I managed to revive my desktop (yay!) and wanted to log in on my server.
Setted up the key and wanted to transfer it to my authorized hosts file… but that gave me a bloody error:

Permission denied (publickey).

So I started to digg around and checked filepermissions, ssh_config file etc… But all seemed ok.
But then I found this little nasty openSSH Bug on launchpad.

Simply running “ssh-add” on the client fixed the problem!

Ssh-add adds identities to the authentication agent, sshagent. When run without arguments, it adds the file %HOME%/.ssh/identity. Alternative file names can be given on the command line. If any file requires a passphrase, ssh-add asks for the passphrase from the user.

I’m not sure how this could’ve helped, but hey, its a workaround that actually works 🙂

Call for participants Dipro-fair Ghent 30/01/2011

Wanted:
People who want to help out at the Ubuntu booth during the Dipro-fair is in Ghent on January 30, 2011.
If you’re not able to attend the full day, some hours of help are always welcome as well.

Profile:
You don’t have to be an Ubuntu/Linux expert.
If you can testify about your experiences and suggest to Windows-programs,
can already make a difference.
Most people we lend a word on the fair, have none or little of Ubuntu/Linux/Computer experience.

Fun fact:
As an exhibitor you don’t have to pay the entrance fee, but between helping out, you can take our time to look around and find awesome deals.

How:
Add your name to the ubuntu-wiki page:
https://wiki.ubuntu.com/BelgianTeam/ComputerFairs/Ghent_2011-01-31
OR
Let me know trough mail ubuntu@mimor.be

Please in both of these cases, mention whether you’ll be helping out a full day or several hours.
That’s all you need to do.
If you can provide items such as demolaptop(s), camera, etc. .. you may also add it to the wiki page.

Hope to see you soon.

=====================================

Gezocht:
Mensen die willen helpen op de Ubuntu stand tijdens de Dipro beurs in Gent op 30 Jan 2011.
Indien het niet mogelijk is om de volledige dag aanwezig te zijn, zijn enkele uren hulp ook altijd welkom.

Profiel:
Je hoeft geen Ubuntu/linux/computer expert te zijn.
Als je kan getuigen over jouw ervaringen en uitleg geven over alternatieven voor Windows programma’s,
kan je al een verschil maken.
De meeste mensen die we op de beurs ten woord staan, hebben helemaal geen of weinig van Ubuntu/Linux.

Leuk weetje:
Als medewerker van de stand hoef je geen toegangsgeld te betalen, maar kan je tussendoor wel rond kijken en toffe deals vinden.

Hoe:
Voeg je naam toe aan deze Ubuntu-be Wiki pagina:
https://wiki.ubuntu.com/BelgianTeam/ComputerFairs/Ghent_2011-01-31
OF
Laat het me weten via mail op ubuntu@mimor.be

Gelieve in de twee gevallen te vermelden of je een volledige dag of enkele uren zal helpen.
Dat is het enige dat je hoeft te doen.
Indien je items van de lijst kan verzorgen zoals demo laptop(s), fototoestel, etc… mag je dit ook telkens aanvullen op de wiki pagina.

Hopelijk tot binnenkort.

Mvg,

Mike Morraye

Ubuntu 10.04 (Lucid Lynx) Release Party Ghent is under construction

It’s official! There will be a Release Party for the Ubunu 10.04 (codename Lucid Lynx) in Ghent.

I’ve just send out the news to the mailing list of Ubuntu-be and the Whitespace to confirm that i’ll organise the release party for the upcoming LTS version of Ubuntu.
The event will take place Thursday the 13th of May in the Whitespace.
I’m still looking for people whom have some knowledge of something Ubuntu-related and have the guts to give a lightningtalk or a demo.
At the moment of writing, I’ve had 1 confirmation from a guy with Balls! Mandel.
He did a talk about desktopcouch at fosdem this year, and will bring an improved version of that to the Release party.
If you have questions, let me know.
I’m available at the #Ubuntu-be channel on freenode, or just PM me (mimor) or use the comment section below.

The sent mail in English:

Hello to all.
>
> I organize a RP on the 13th of May in honor of the Ubuntu 10.04 (Lucid)
> release.
> This is indeed a Thursday 🙂 but that’s an official holiday and lot’s of
> the people don’t have to work on Friday.
> What time it’ll take place is yet to be decided.
>
> The RP will take place in the Whitespace (Blekerijstraat 75, Gent,
> Belgium)
> For people wondering what the Whitespace is: http://0x20.be
>
> The space has: power, network, internet, drinks, snacks, beamer, couches
> and I hope we can repair the coffee-machine by then.
> People whom want something else, mention it.
>
> The program is still under construction.
> This moment, my receipt looks like this:
>
> Around 13h we’ll serve a light meet & greet to loosen up the nerves.
> Next, we’ll stimulate the senses wit a series of lightning talks
> accompanied by a spicy serving of freshly cut tips.
> As the Spécial-du-chéf, you can enjoy some trial-and-error-sauce topped
> hands-on sessions.
>
> This part is for sure, but the rest is still work in progress!
>
> This is the rest:
>
> – design of Posters, flyers and web-banners
> – do you know someone, or want to present something yourself? Go for it
> & let me know.
> – spread the word! To your friends, colleagues, your student-club, etc..
> – the pleasure to have YOU with us!
>
> Regards,
>
> Mike Morraye

Or in Dutch:

>
> Hallo iedereen.
>
> Ik organiseer Donderdag, 13 Mei 2010 een RP voor Ubuntu 10.04 (Lucid).
> Dit is inderdaad een donderdag 🙂 Maar het is een feestdag en vrijdag is
> voor velen dus een brug-dag.
> Van hoe laat tot hoe laat is nog te beslissen.
>
> De RP gaat door in de Whitespace (Blekerijstraat 75, Gent, Belgium)
> Voor wie wil weten wat dit is: http://0x20.be
>
> Locatie heeft: stroomvoorziening, netwerk, internet, (fris-) drank,
> versnaperingen, beamer, zetels en hopelijk kunnen we tegen dan ook de
> koffiezet herstellen.
> Wie nog iets anders wil, laat het gerust weten 😉
>
> Het programma in nog in ontwikkeling.
> Op dit moment zit m’n recept er zo uit:
>
> Rond 13h serveren we een luchtige meet & greet om de zenuwen wat los te
> weken. Hierna prikkelen we de zintuigen met een reeks van pittige
> lightningtalks vergezeld van een portie vers gesneden tips.
> Als spécial du chéf, kunnen de fijnproevers genieten van enkele hands-on
> sessies overgoten met een sausje trial & error.
>
> Dit stuk is zeker, de rest is work in progress!
>
> Hier dus de rest:
>
> – ontwerp Poster & flyer en/of web-banners?
> – ken je iemand, of wil je zelf iets presenteren. Go for it & let me
> know.
> – Spread the word! In je vriendenkring, op het werk, in je
> studentenclub, etc…
> – het genoegen dat JIJ er ook bent!
>
> Mvg,
>
> Mike Morraye

Going to Fosdem 2010

FOSDEM, the Free and Open Source Software Developers' European MeetingIt’s finally there. The 10th edition of Fosdem.
For the people whom don’t know Fosdem (yet):It’s the finest free and non-commercial event where FOSS developers and communities can meet.There are a lot of interesting talks and demo’s, food, drinks, booths, and if you search good enough you might encounter a (real) girl.
And the best thing… it’s in Belgium :)Here’s a list of talks I’d like to attend

Saturday

  • 11:45 to 12:30 Evil On the Internet

    This talk will show you live examples of these sites, explain how they work, and tell you what we currently know about the criminals who operate them.
    There’s a lot of evil things on the Internet if you know where to look for them. Phishing websites collect banking credentials; mule recruitment websites entice people into money laundering; fake escrow sites defraud the winners of online auctions; fake banks hold the cash for fake African dictators; and there are even Ponzi scheme websites where (almost) everyone knows that they’re a scam. This talk will show you live examples of these sites, explain how they work, and tell you what we currently know about the criminals who operate them.

  • 13:15 to 13:45 Mozilla Europe

    General Introduction followed by an update on the work of Mozilla in Europe.

  • 13:45 to 14:00 Mozilla Foundation

    Latest MoFo news and projects.

  • 15:30 to 16:30 HTML5
  • Continue reading Going to Fosdem 2010