Linux.com

Home Linux Community Community Blogs

Community Blogs



openSUSE Weekly News 174 is out!

We are pleased to announce our new openSUSE Weekly News Issue 174.

In this Issue:

  • Alex Eftimie: GSoC 2011: PackageKit and AppStream integration for Software Center
  • Sebastian Kügler: Plasma Active at Tokamak 5
  • openSUSE Ambassadors are rocking all over the world
  • h-online/Thorsten Leemhuis: Kernel Log: Coming in 2.6.39 (Part 3) - Architecture and infrastructure
  • and many more ...

You can download it there:

We hope you enjoy the reading :-)

If you want to help us collecting interesting articles for the openSUSE Weekly News, so you can all your stuff into our new ietherpad: http://os-news.ietherpad.com/2.

Found Bugs? Please place it in our Bugtracker: http://developer.berlios.de/bugs/?group_id=12095

Features, Ideas and Improvements can placed in our Featuretracker: http://developer.berlios.de/feature/?group_id=12095

Older content can be found there.

Flattr this

 

Using Ubuntu for Work/Play

Having been a student by day filmmaker by night.Ubuntu has really helped my quite a real bit.

Cinelerra,Kdenlive etc have helped me in many way for my film making process.As for being a student, Open Office Org has helped me create professional looking documents,letters(excuse letters) and even help build a website with HTML.

Being a filmmaker i do eventually need to do sound and video editing of some sort.Which brings me to my next question.

How do i incorporate Linux(Ubuntu) into my hobby?

Ubuntu is open source which enables me to save on licensing fees,extra add-ons,expensive new computers for just the new software.This was how it all started my tech guru had an old laptop from the office and had the Windows XP for his work purposes it had all sorts of programmes on it Windows Server to access his virtual office and his infrastructure.the old laptop had started to fail with Windows in it and all the high robust,complicated applications in it functioning,he had gotten a new laptop form the company to replace the failing one.He had use the old one for his personal purpose like watching his comedy shows and doing some mobile surfing at home or even on our holiday in New Zealand.Running on Ubuntu 8.10 it functioned well enough over my expectation.Back then i was living under a rock doing only with what i have and not sourcing out for better methods to do things like Video Editing.I had then remembered my guru sharing with me Ubuntu.

I had picked up Ubuntu again starting with 10.04 recently late last year,trying numerous times to make a download of Ubuntu from my computer and receiving the . ISO image i gave up! i went to shipit.ubuntu.com and ordered my copy of the Live CD it came just about about 8 weeks ago and i have given it numerous test drives without fail having to please me each time i use it. 

My decision was final i had booted Ubuntu alongside my usual Win7 so each time i booted up my computer i would go to the BIOS menu and choose to boot for my other hard drive which had Ubuntu.gives me a chuckle each time i boot up as it always remind me of my past living under a Rock.now Cinelerra, OpenOffice. Org all in my computer each and user friendly.

As for my homework i'm using Open Office to type out essays,really does serve a purpose in my work both in scripting and in homework.

I took the option of using dual booting in my computers used all ubuntu and win combine

 

Now have you tried your fair share of Ubuntu!?!

 

 

 

 

Create a custom distro: Choice of the right base (P.2)

previous page...

 

Debian

This is one of my favorite distribution for servers, when I don't have enough time for a fine tuned HW optimization (Gentoo) or when I don't have so much time to spend on the installation and configuration process (Arch) I usually adopt Debian. With Debian you can do some sort of “dumb/quick installation” (Debian is not dumb!), the installation process gives you a working machine in half an hour. That's what I'm definitively using it on production servers, rock-stable, optimized and well supported. ….but, I've tried to install it in an USB stick with space constraints, read-only root partition and some customizations, you can do it but someone else gives you a better result (read below). I've tried to apply Linux Live-CD scripts for my personal read-only installation, you can do it but I've had few issues, mostly on:

  • startup scripts optimization, I'd like to install packages and modify startup scripts later. If you'd like to have a “prebuilt-template” to apply to it you've to manually add everything later on

  • Debian is not aimed to a live USB/CD environment, it's made for something else (servers for example)

  • root partition is not compressed (knoppix style), you may do it externally. Disk space for a tipical installation doesn't fit under 100Mb. Now “minimal” Debian installation is not so minimal

  • You may do something on a typical installation and then reduce it later on but it's not an automated system and you need to reproduce each step manually every time you need to change something

Sadly this is one of my favorite choices but this is not the right kind of solution to my own problem

 

OpenSuSe

I've not against SuSe, it even has the best tool for building a tailored distro, everything on the web in the cloud, SuSe studio is an impressive tool but:

  • Like Debian their minimal installation is not so minimal, you cannot go under 200Mb

  • You may do customizations on it after the installation but what I'm trying to do is a read-only image

  • Cloud computing is fine for me but I prefer to have my own virtual machines in my own environment and waste my own disk as often as possible, what happens if I don't renew my account or if I don't log often in their website ? What happens if I'd like to work on my own machine and I don't have an Internet connection ?

  • I want to apply patches or modify init scripts for my installation, after package selection but before installation

I like it but as Debian I think it's not aimed to Live-CD/USB creation

 

if you're still reading this article...

Relax, I don't want to write a review about every possible Linux distribution available in our planet, I've really made these tests before choosing the right one (the one I'm most comfortable with in this particular situation). I'd just like to tell you a simple thing:

“every distribution was made for a specific task, you may do everything you want with it but there're easier approaches to your problem every time you need something different, an easy approach with a specialized distribution is always preferred if it doesn't compromise stability, speed and optimization“

I've really spent a lot of time to find out possible solutions with all these listed distros and I've finally decided to use a distro for their unique characteristics. My final choice for this particular problem is : SLAX. If you're still reading this article and you're still interested in my decision here are topics achieved with it:

  • I was using LiveCD Scripts (they're very popular) with LFS and Gentoo, I think this the best approach and the simple one

  • You don't need to deal with targeted/specialized packages (legacy distro packages: gentoo, ubuntu, fedora, ...) to build a live appliance, you've a live distro aimed built around live CD creation

  • you've a modular approach, this is tipical in a live cd environment, on slax there's just one required package: “The Core” (~50Mb), everything else is an option

  • You've AUFS (http://aufs.sourceforge.net) ready to use and it's already there

  • Every “module” (a package) is compressed and easily pluggable into your own personal system, you just need to copy it into the “modules” directory

  • You may create your own LiveCDs or LiveUSBs in just few minutes

  • Documentation is simple

  • You may add your own scripts or alter final file system structure just by adding files to the final root dir. This is the thing I love more, SLAX is using UnionFS approach to make live customizations. If you don't know UnionFS take a look at http://en.wikipedia.org/wiki/UnionFS, this is one of the biggest benefits when dealing with live distributions

  • It's based on Slackware, that's one of the reasons I've never cited it in the first part of the article. Slackware has a lot benefits for this kind of system but SLAX is really focused on my own system

  • A lot of cool different projects are using it for live cd tools (registry editors, demos, security, auditing, ...)

I was discussing in the forum section of this site about Live CD scripts a month ago with other folks, obviously Slackware addicted guys (:-) Matthew, Eric, … thanks :-) ) were more focused on it, I was already using it but I've always used it as the “Slackware little bro”. I've ran it few times (auditor, …) and used it for a while but I've always left it in a corner.

But after spending weeks with LiveCD scripts (http://www.linux-live.org/) and other distros (mostly LFS, Gentoo and Debian) I've decided to use them in their “original environment”: SLAX.

It was damn easy to use it, customize a current Slax installation, produce my own USB install, create and port new packages to it. In just half an hour (GCC installation time on Gentoo...) I've created my Slax build station and I was ready to create USB sticks. Everything available from the original Slax environment, easy customizations, minimal footprint (my first install: 80Mb!) and no external tools involved in my process creation. Just a file manager to handle/copy files and few minutes for everything ! That's what I need and this is definitively what I need to finish my appliance.

 

Where's the code ? Where's the solution ?

System requirements, hardware selection and distribution choice are mandatory sections (even the boring ones) for a project like that, in the next section I'll start with hands on descriptions and I'll start publishing some code involved in this particular project. I've decided to explain my specs with these chapters so I may start a discussion with you about the overall project, I could start my articles with sentences like: “I use Slax to do that” but maybe building a custom Linux distro it's not so appealing if you don't know the reasons and initial requirements

 

As usual feel free to add your comments or discuss about my choices.

 

Andrea (Ben) Benini

 

 

Previous chapters:
Choosing the hardware
Creating a live distro for target appliance

Next chapters:
Create a custom distro: building the build machine

Create a custom distro: building the first target machine

Building a minimal image

 

 

Create a custom distro: Choice of the right base (P.1)

Intro

I'm still following base directives for creating a custom live distro for a special appliance, you've certainly read my previous considerations related to hardware and initial planning requirements. For this particular home server I've decided to stay with a common x86 device, power consumption could be a big issue if compared to low power CPU boards (MIPS and ARM devices for example) but at least I've an huge choice and many different Linux distributions.

I've decided to use an Atom based motherboard with an Intel NM10 chipset, an Atom N450 CPU is big enough (even too big...) for my designed tasks but I've decided to install a tailored Linux distro instead of installing a full blown stock distro. If you've read my previous considerations and constraints I'd like to achieve these tasks:

  • No further modifications are needed on this appliance after initial installation

  • I've already decided basic services this appliance should provide to my home network

  • It's not a desktop, there's no mouse, keyboard, screen or whatever, it has to work on a LAN, no direct user interaction

  • It must run unmanaged or without an IT specialist around for a long period, I often spend a lot of time away from where this machine is, I don't have a skilled user and I don't even need it to run this device.

  • It's just a stupid appliance, no frills

  • To avoid HW failures I'd like to reduce breaking parts, no fans, no hard drives, no SDD. This board needs to be attached to a common (and cheaper and easily replaceable) ATX PSU. Again: no moving parts or fan around. I've few power supply units with low specs and low power consumptions, I've just used one of them

  • Hard drives may fail, to replace them easily I've decided to run everything without an hard drive, I've decided to use a cheap and common USB Key as primary root disk. To avoid troubles with cheap USB keys I've decided to use one of them and have at least a backup of it elsewhere, if I need to replace my “main USB root disk” I only need to throw away the bad one and use a new one

  • To avoid troubles with USB sticks and possible breakage in the long term I've decided that my root disk has to be read only, USB sticks are excellent devices when you only need to read them, you may corrupt them easily in the long term if you write data on it (it's still a flash..., it has limited write cycles)

  • It has to be a thin distro so I can use cheap USB sticks, I don't need a 4Gb USB stick just for running an OS with few basic services. In my case I've decided to stay under 128Mb, there are plenty of sticks around with 128/256/512Mb and they're so cheap...

  • I don't want to keep basic distro behavior and I obviously need some customizations on services, networking and some special personal needs

  • I want to build my personal toolchain to be able to reproduce the same image and do more customizations on it

If you've carefully read my specs and you tend to keep a small footprint on tailored machines like me you've probably understood why I haven't even considered to install mainstream distributions like Ubuntu/Fedora Core/Mint/... I'm not against them but these are for a common desktop user and full of unused utilities (even bloatware sometimes...) and not really optimized for my special task so I've started to consider other distros I already use, here are my thoughts:

 

LFS (Linux From Scratch)

This is definitively my first choice and the approach I prefer with my personal computers, it's not even a distro (it's just a series of books). THIS IS LINUX AND GNU, nothing more. You've the GNU operating system and a Linux kernel, this is the approach (not even a distro) for the definitive geek. You can do everything you want with it: you may customize scripts, dependencies, packages makefiles, your toolchain and build scripts as well. It takes a while (!!!) to compile everything but at the end you have your own Linux system with LSB compliance as well. This is what we all need to use all the time... but.... in this case this is not what I've used, that's why:

  • x86 support for LFS is excellent and the base book is really something to read at least once in a lifetime. I've my own build script (a set of bash scripts and makefiles) to automate the whole process, even with this magical script my installation procedure after some changes takes at least: 6-8 hours for building the base toolchain, 4-6 hours to build my basic system. When you test it or when you make some trials to adjust your internal requirements you may spend a week on it just to make some tests, that's definitively what I don't want to do

  • An LFS installation process gives you a full blown GNU OS with a Linux kernel, installation takes across 300-400 Mb (for a bare bone system) or more probably around 500-600 Mb (samba, httpd server, php, DLNA, torrent, …). You may tweak it with a busybox but it requires extra steps, even binary stripping is required but this is not so easy, you may even cut unnecessary man pages as well as other things (you already have manuals somewhere...). More extra steps, more time to realize the project

  • It's not aimed to be a read only system, you obviously have the Live CD and some scripts but if you tend to recreate your system frequently you need extra time (again), live cd scripts (www.linux-live.org) are impressive but LFS needs a lot of care

  • There's no automatic HW recognition (it's not so important BTW)

  • Your live image it's not compressed (like knoppix or stuff like that), you may do it because you've “the father of every Linux distro” but again: it requires a lot of extra time

  • UnionFS, and aufs may be attached to it to support some sort of changes in a read-only environment but it's a slow process if you need to implement them

Conclusions:

This is my best choice and my first attempt but unfortunately I'll be able to build my own system in a month or maybe more and there are even things I don't even know how to realize. I really appreciate LFS books and it's still one of my favorite “distros” (even if it's not a distro !) but I cannot use it in this moment

 

Gentoo

I've started with Gentoo in 2000-2001 when it was a young distribution, I was looking for a distribution with these requirements:

  • It has to be really close to LFS approach, in the beginning I've started with it because it was something like “LFS with steroids”: an LFS install with an automated build script

  • I'd like to have a “super-build-and-do-everything-for-me” script to create a running installation without worrying about copying and pasting instructions from the book. I don't want to read the same paragraph 100 times to discover after few hours what kind of instruction I've missed before

  • I've been an happy BSD user and I really love it, one of the best things about BSD is their makefile approach. When you need a program you just need to enter in their package structure, locate your favorite program (just use “find” utility), and install it with make (make clean, make, make install). Even better: you want to upgrade your whole system to current stable BSD ? Just issue “make world” and your machine will upgrade itself and install everything needed (well, it's not so simple but this is the approach). I respect monthly scheduled released distro (6 month for SuSe, Ubuntu, Fedora, …) but I'd like to have “the latest one” just with a simple upgrade command.

  • Gentoo and Arch are rolling update distributions, there's no version vX.xx, there's “the distribution you're using” and “current distribution”, with a simple command you switch from “your old one” to “current”. I really love rolling updates distros

Even more: do you want to make your favorite customizations to every package because you want or don't want that particular feature (doc, man pages, Xorg, Lang, ...) ? Are you looking for a special patch or an optimization for your particular CPU ? Gentoo is the way to go. This is my first distribution and what I use more at work (my main desktop) and at home, it was obvious for me to test it and adapt it to my appliance. But even if I still prefer Gentoo I've discarded it, that's why:

  • If you need to create a system with a limited space (my USB stick) you need to drop portage directory structure and create a system without it. There's a way to do it (read excellent Gentoo docs) but it's not so easy if you want to make frequent changes to it or do minor upgrades

  • You need a “build machine” with a full Gentoo installation and a special portage structure for creating your target machine, cross compilation it's one of the Gentoo specialties but it's not aimed to machine creation

  • There are tools like Catalyst or tools/docs for creating “stage 4” steps but these are a little bit cryptic and sometimes aimed to create other Gentoo tipical installations, most of the times you've excellent results when you need to deal with a LiveCD but it takes a lot of time. I've used catalyst a while but it's not so easy to create a live image under 200Mb ! It requires lots more

  • There are Live-USB methods, something with AUFS or UnionFS but it requires a lot to reproduce them all and there's no root disk compression (like Knoppix for example). You obviously may do it but it's like LFS, it takes a lot of time to do it

  • If you upgrade your “build station” and “toolchain” frequently you always need to make few adjustments to the build system if you've modified startup scripts for your target machine

Sadly I've discarded it due to some problems: available time, overall image size, readonly unavailability and live cd/usb compression. It's still my favorite choice for a full blown desktop or server but this time I've used something else for my installation

 

Arch

I really like it because it has the same rolling update approach like Gentoo, there are no “major versions” there's just the version you're using and the current stable, current stable changes every hour (depending on project activities...). Even more: it's definitively binary based so you don't have to wait ages to get something compiled (emerge, emerge, emerge, …), you may loose 0,00001% optimizations from your particular HW but someone still lives without it. But my poor Arch knowledge drove me to nothing, I'm an happy Arch user, I use it for building tailored servers for example and it's nice but it seems it's not really oriented to LiveUSB/CD creation like others (read below). You may use Arch for Servers or Desktop installations but in my particular case I've chosen to use something else

 

continues on the next page...

 

 

Previous chapters:
Creating a live distro for target appliance
Choosing the hardware

 

First Time at the 2011 Linux Collaboration Summit

<!-- @page { margin: 0.79in } P { margin-bottom: 0.08in } A:link { so-language: zxx } -->

LINUX COLLABORATION SUMMIT: Celebrating 20 Years of Linux

On April 6-8, was a memorial event. From all over the world, individuals with marvelous talents came together under one building to share ideas, teach one another and meet for the first time. Most importantly, we all came to celebrate linux’s 20th anniversary.

I was one of the lucky ones to have been honorably invited to sit and chat with some of the greatest minds the world had produced. It was intimidating at first, since I have never been to such a gathering of this caliber. Plus, these gurus knew more about linux than I can ever dream of. To keep pace with these specialists, I said little and kept my ears opened to learned as much as possible.

The atmosphere was peaceful, the people were friendly, and most importantly, they encouraged you to participate, add thoughts, ask questions and just plain mingle. It was almost like a family reunion, reconnecting with long lost relatives.

I met up with three friends who's skills in linux are very unique. This was the first time we met face-to-face, from constant online chatting, and gotten along very well. One of them, who is actually the “2011 Ultimate linux Guru” on Linux.com, Mathew Fillpot, had been there last year and showed us around. We had the honor of meeting Jennifer Cloer, Director of Communications & Community at The Linux Foundation, and PR Director at linux.com, a site that allowed me to enter the world of linux. It was also through this site that allowed me to meet these fascinating individuals.

After meeting a few special attendees, the four of us, and all the other guests gathered in an auditorium at hotel Kabuki, where Jim Zemblim, Co executive of the Linux foundation, opened with a speech explaining the direction linux was heading. Afterwards, the attention was turned to members of various companies to talk about opensource projects they were engaged in. From these panels, it was made aware of the increasing activities involving linux. And, more is to come.

After the panel speeches were done, we were all invited to a prestigious restaurant that served delicious food all night. This was good to break the ice for newer members. There is nothing better than good food and good conversation with people of the same genre. Have to admit, during this particular time, away from the keyboard and monitor, we were just a bunch of ordinary people having a good time. You wouldn't notice the difference.

The next 2 days involved workshops sessions for various linux projects, for example, Yocto, Embedded linux, linux standard base, etc. In these sessions, detailed explanation were given regarding project motives and how they function. The audience of these sessions freely gave their opinion about the development of these projects and any concerns and confusion they had. The speakers did a very good job distributing the information and answering questions. This assures the projects are being handed by the most dedicated and skillful professionals. Ok, I will say it, it was like being back in college on the first day.

Yet I’ve saved the best for last. Not only was I invited because I was within the top 5 2011 Linux.com Gurus, but also, I’m one of the 4 moderators of linux.com. As a moderator, you are in-charge of hunting down spam and any kind of site abuse, with the addition of information contribution and consulting. Moderation was voluntary, however, it allowed me to give back to the community that helped so much in my progression of learning GNU/Linux.

linux.com had a session at the Summit called the linux.com planning meeting” where the site admins and the moderators got together to discuss any improvements and concerns about the site's community section. This was a thrilling experience. In that room, giving input on how the site could perform better on its relation to the community couldn’t feel any better. Even as nervous as I was, there was no hesitation to take advantage of the opportunity to have make an impact, and I;m ready for more.

I wished I picked up on linux a long time ago. One of the important things that I've learned is that linux is also a community of collaboration not just people programming and building the latest hardware for maximum optimization, although, a lot of that goes on. Yet we all share ideas and look for opportunities to improve business operations and help one another. Couldn't be more happier to part of this great organization. 

 

Resizing a SAN attached volume without rebooting

Ever needed to add some extra space to that LUN on your server, but doing so you think you might need a reboot for the server to recognise the additional space?

The following set of steps talks through what needs doing to avoid that reboot!

Firstly, I should make it clear that this article assumes that any volumes needing expansion are additional volumes and do not include the disk or volume containing the running operating system, the steps required to extend OS partition are different. Also a warning point, several of these steps carry potential risk for data loss if you are unsure or make an error, always have a backup handy before manipulating your filesystems and devices

Here is the scenario: I have a SAN-based data volume named "/my_data" which is currently 20GB in size. I need to extend this filesystem to a new size of 40GB.

My first job is to log into my SAN appliance and extend the LUN containing "/my_data", as there are many SAN vendors and technologies available I have omitted describing this step in any detail. Suffice to say in my SAN administration console I will add an additional 20GB to the LUN containing "/my_data" to make it a total of 40GB

One warning point for my current SAN is that I need to umount "/my_data" so that it is not being accessed whilst the SAN extends the LUN. Once this task is completed we are ready to move back onto our Linux Server to prepare the volume for its new space.

If we now remount "/my_data" we will see that it still shows as having still only 20GB available, for the purposes of this article the disk device we are presenting to the operating system from the SAN shows in the server logs as /dev/sdb1, and is mounted at "/my_data".

1.  mount /dev/sdb1 /my_data

2. df /my_data which shows 20GB. - Utils like fdisk at this point will also still see the old value.

3. unmount /my_data again to perform the next step.

Running scripts like rescan-scsi-bus.sh will also normally fail to pick up the changes.

Next step is to type the following command into the shell, Here is the magic bit that means we dont have to reboot:

echo 1 > /sys/block/sdb/device/rescan (where sdb is your chosen disk device number).

As the command suggests this instructs the system to rescan the specified device, and check for changes.

After this operation completes using fdisk or something like YaST partition manger will reveal the extra space. However, this doesnt mean that the new space is available for use yet, the filesystem that is already on the disk needs to be told about the extra space.

You can then use GParted(Very user friendly) or your preferred partition manager to extend the extra space into partition /dev/sdb1. When this is done, re-issuing the mount command will reflect the new space, all of which was possible with no reboot!

 

 

 

 

LDR: The birth of a Linux distro - Part 1

So I've always been a huge fan of Arch Linux. For many years it has been my weapon of choice for pretty much anything from web servers to development environments. It's incredibly lightweight, fast, stable yet up-to-date, and highly customizable.

Sure it doesn't have all the bells and whistles of other distros, nor does it take the responsibility of configuring complex areas such as Sound support or Network hot-swapping; but I think this is quite healthy... I spent years swearing at Microsoft products because they feel they have to do everything for you (no matter how complex) and then things just didn't work. Ironically if they have left things lite and transparent and left the responsibility of getting it working to best suit my requirements to me, then I wouldn't have held them responsible when something wouldn't work.

Thankfully I am out of that world now, and am taking what I have learnt from it with me.

My biggest issue with Arch was that it would take an entire evening to get everything I need installed and configured the way I like it. So I eventually decided to invest some time into creating my own derivative.

This derivative included my own custom repository, so I can install my packages I have acquired from various places (or written myself) from a single command.

It also contains configuration changes to the core platform, so it behaves the way I want it to (and sports my own branding!)

Hunting around the Arch forums, looking for people who have done something similar, I stumbled upon a set of script files called archiso. Unfortunately I couldn't get archiso working straight away, as there was some problems with the Makefile included on the Arch wiki. I began to edit it, adding my own parts so it could do extra things like branding.

To be able to create a derivative, I first needed to brush up on how a Live CD works. The best way to do this is to break the boot sequence into logical chunks:

The Boot Loader

The boot loader is the first component to be loaded. Arch CDs use the ISO version of SYSLINUX (ISOLINUX) which lives in the /boot folder. It loads up and reads the config file /boot/syslinux/syslinux.cfg which gives it a list of boot configurations (eg. which partition, initrd, kernel, kernel boot options etc..) that can be loaded. Once one of these is chosen, the kernel is executed using the chosen options.

Initial Ram Disk

Also known as "early user space", the initial ram disk is an image which contains the kernel and a super lite root filesystem which is just enough to prepare the system for the real root system to be mounted. This involves running kernel hooks and hardware detection.

You can create an initrd by using mkinitcpio with a config file which contains a list of the kernel hooks that need to be run during this early boot stage.

One of the hooks for Arch's Live CDs reads a file on the root of the CD called isomounts. This is an fstab file for the CD. It mounts the root file system and the Init scripts gets run.

Init scripts

The init scripts begin with inittab. This is a file which determines which runlevel should be ran (these tend to be different for each distribution, but 3 generally means a multi-user environment with networking, which is the default for arch). 5 means the same, but with a desktop manager (eg. GNOME, KDE, OpenBox, FLuxbox, wmii, dwm etc..). inittab is also the script which is responsible for respawning the login manager if you kill Xorg.

Arch also has a load more init scripts for various purposes, you can read more about them here. rc.sysinit runs on boot; it does more hardware configuration, logs to dmesg, starts the daemons etc.. Followed by rc.multi and rc.local which contains any finish up code before the login is displayed.

LDR Linux

So I now have a working Arch derivative with all these steps configured. You can check it out at: http://www.tommed.co.uk/ldr. Obviously, as Arch is GPL based, I have open sourced by build scripts and packages here. I hope it is of good use to people who want to do the same, or use as a learning tool!

I released LDR recently as an ISO image, but didn't quite realise the impact of doing so... I was added to Distrowatch and quickly started receiving thousands or hits per day, which quickly destroyed my little home web server! :(

I managed to get the ISO mirrored (BIG thanks to Neil Bright of Georgia Tech) which deferred the bandwidth load from my home server, which runs quite happily again now! 

I didn't released LDR Linux planning on turning it into the next big distro, it was more about being able to quickly install Arch with all my custom trimmings in less than 1hr and also  sharing my code and my work to inspire others, but from the feedback I have received, it's plain to see that others want LDR on their machines + they want it supported too!

I am happy to do this, but could use a bit of help from anyone in any capacity (even if it's just spell checking on the wiki, or general testing) any help or donations would be greatly appreciated!

Google Chrome, wmii, OSDBattery (run battery-status or Mod4+B), Adobe Flash, and PulseAudio all work out-of-the-box when testing in VirtualBox!

LDR Linux 1.06

 

 

The GNU/Linux Adventurer's Backpack

If you are setting off on your new GNU/Linux adventure, there are some must have things that you'll be needing to take along with you.

When you're at the kitchen table packing that backpack for your big adventure, don't forget to stuff these items in there with your lantern, matches, water purification pills, and lip balm. You'll find this stuff will come in very handy along the trail.

A little history --

Linux, which specifically means the kernel portion of the operating system, was born in 1991 when Finnish student Linus Torvalds decided he wanted something to run on his 80386 processor based PC. Linus turned the code for his new kernel lose on USENET.

Within a short while Softlanding Linux System (SLS) was born of a mating of Linus' new kernel and Richard Stallman's GNU Operating System. The SLS project was taken over by Patrick Volkerding, who morphed it into Slackware Linux, the oldest still living GNU/Linux distribution. You can view the Linux family tree to see how things progressed from there.

Some handy documentation --

C'mon. Quit whining. Sometimes, it's a good thing to read the fine manual. The "man" pages, short for manual, are available to you from within any GNU/Linux distribution. They're already in your backpack even if you didn't know it. To access a manual page for a certain command within Linux, just use this from the command line:

$ man <command or application name>

For example, let's say you want to know how to use the ls command. You would type this into the command line:

$ man ls

LS(1)                            User Commands                           LS(1)

NAME
       ls - list directory contents

SYNOPSIS
       ls [OPTION]... [FILE]...

DESCRIPTION
       List  information  about  the FILEs (the current directory by default).
       Sort entries alphabetically if none of -cftuvSUX nor --sort.

       Mandatory arguments to long options are  mandatory  for  short  options
       too.

       -a, --all
              do not ignore entries starting with .<snip>

...and the manual page for the ls command will magically appear. Cool, huh? You can also refer to that same manual page by using online websites that make that same information available to you. You can use Linux Man Pages, Linux Man Pages Online, or other similar sites.

For some more in depth GNU/Linux documentation, you can check out The Linux Documentation Project (TLDP), LinuxDocs.org, or DistroWatch.com. The last provides brief synopses and reviews of most of the GNU/Linux distributions available today.

Which distribution to start the adventure? --

If you clicked on that DistroWatch link above, you'd see that there are many, many GNU/Linux distributions out there in the world. While choice is a good thing, numerous choices can sometimes be overwhelming for new adventurers; what trail should I take? Every GNU/Linux advocate will have their own favorite list of distributions that they recommend to all the new adventurers they run across. Following is my list of the five easiest transition distributions. What's a transition distribution? I define that as a GNU/Linux distribution that is easy to install and use right out of the box for new adventurers who are mostly used to using Microsoft Windows products.

Ubuntu - this is the distro that took GNU/Linux from the desktops of geeks like me and put it on Gramps and Granny's system. It did more to popularize the GNU/Linux operating system than any other distribution prior.

Linux Mint - this distro from the land of Eire is slam packed with all the great stuff you'd want in an operating system. It's good to go right out of the box.

Mepis - while not the most popular GNU/Linux out there, this Debian-based distribution is a fine product, and most suitable for new adventurers.

PCLinuxOS - this distro is a branch of the old and venerable Mandrake/Mandriva GNU/Linux. It's easy to install and to operate.

Ultimate Edition - this distribution gets its foundation from its Debian and Ubuntu roots. It is also easy to install and has loads and loads of useful software included the moment you boot up.

OK, then. We have some history, some documentation, and a choice of distributions in our backpack now. We're almost ready to begin the adventure. But wait! There are a couple more very important items that we'll be needing.

Tips and Tutorials --

Tutorials are documents that teach in a step-by-step fashion. They can cover a lot of information in a small space. They're usually simplified so that amateurs and novices can follow along without the need to know the really complicated stuff underneath it all. Tips are just that; little tid-bits of information to make things go easier on your adventure.

There was once a man called Bruno, he was my friend. He was also a serious GNU/Linux advocate and teacher. He selflessly spent many hours of his daily life teaching others about GNU/Linux. Many of us who knew him learned from him and were inspired by him to carry on his tradition of teaching. While Bruno may no longer be with us, part of the legacy he left us is his Tips for Linux Explorers site. Yes, some of the info there is a bit dated, but most of it is still very relevant and helpful.

As far as tutorials go, there are many sites with wonderful GNU/Linux tutorials. Here are a few that I use regularly: The Linux Tutorial, YoLinux Tutorials, Linux Survival, HowtoForge, Tutorialized, and Linux Planet Tutorials. Believe me, if there's something you want to accomplish within GNU/Linux, there is a tutorial somewhere that will show you how. Remember, when searching for answers to your GNU/Linux questions, Google is your friend.

And lastly, but never last, this most necessary thing to have in your GNU/Linux adventurer's backpack:

Community --

We come into this world alone and we leave it alone, but fortunately, while in this world, we have each other. Were it not for the GNU/Linux - Open Source community, there wouldn't be any GNU/Linux; or if there were, it would be some ghastly thing used by a few uber-geeks in the darkness of night on their own desktop systems. Joyfully, that isn't so because we have community; arguably the most important ingredient in the brewing pot.

There is a large and very active GNU/Linux - Open Source community every where in the world. You can access and interact with that community in many ways; boards and forums, USENET Groups, mailing lists, websites and portals, blogs like this one, etc. Community means a lot to me. Below you'll find my list of favorite places where I go to learn what I need to continue on my own adventure:

Boards and Forums

Scot's Newsletter Forums - Bruno's All Things Linux - a Linux support forum and much more. This site is run by Scot Finnie, Editor-in-chief of ComputerWorld.com.

Jeremy's LinuxQuestions.org - a Linux support forum and community dedicated to assisting adventurers of all skill levels and abilities.

TechSupportGuy Forums - Linux and Unix - another excellent Linux community forum.

The Linux Foundation's Linux.com Community - a relatively new and growing community with many helpful members.

Just Linux Forums - a great community resource.

Linux Forums - search this place for great tips and assistance as you travel along in your adventure.

Also, don't forget... nearly every distribution of GNU/Linux has its own very helpful support community. Check out the main websites for links to their forums and such. All the distros mentioned above have their own forums. Check 'em out.

Linux News Sites

Tux Machines - Susan Linton's wonderful Linux community site.

Linux Today - news you can use.

Linux Insider - more informative Linux news.

LXer Linux News - the world is talking about GNU/Linux and Free/Open Source Software.

The above are just a sampling. There are literally hundreds of top level, informative Linux news sites on the Net. Search!

Linux Learning Blogs

Linux Operating System - Guillermo Garron's very helpful and informative blog.

Linuxaria - Ricardo Capecchi's bi-lingual Everything About Linux blog.

All About Linux - a self-professed "very" popular blog about Linux, Open Source, and Free Software.

Linux Notes from Dark Duck - helpful information on choosing and running Linux on your systems.

Dedoimedo - a place to learn a lot about a lot. A unique experience, I might add.

There are many more sites out there, too. Each distribution usually has a handful of dedicated bloggers and teachers running from their own websites. Don't forget to search online. You'll find some wonderful stuff.

One other thing you can do when starting out on your adventure is to register with The Linux Counter and be counted as part of the community. Proudly display your Linux Registered User number for all to see. Sorry, they're out of stock on the super-dooper decoder rings, though. You may find one in that Cap'n Crunch serial box on your kitchen table. ;)

I've tried to make this as all-inclusive as I could, but of course, I've failed miserably. GNU/Linux is a topic that volumes have been written about. How could I possibly give you all that information in one short article? Oh well. I hope that what you do find here will help you along in your adventure. I leave you with three bits of wisdom that I learned early on when I first started out on my adventure:

  • First and foremost, GNU/Linux is NOT MS Windows. Please don't expect it to be.
  • Secondly, KEEP notes! You will find this an immeasurably important practice to discipline yourself into doing regularly. I don't care if your notes are on your iPad or your main system or on a dead tree note book (my choice medium). Just keep notes. You won't regret it.
  • Lastly, but again NEVER last, the community is there for you. Take from it all that is offered, so that you can learn and expand your horizons on your great GNU/Linux adventure. We ask only one thing from you in return; when the time comes that you have reached a level of knowledge where you can comfortably (and accurately) do so, please give back to the community that supported you. This way there will always be those willing to help the new GNU/Linux Adventurers coming along the trail.

Happy adventuring!

~Eric

P.S. I intend this document to be a living device. I will probably be amending it from time to time.

*This article originally appeared on my Nocturnal Slacker v1.0 blog at Wordpress.com

 

 

 

Multi-booting My Way (Not Necessarily the Easy Way)

The following is a brief step-by-step on how I've been multi-booting different operatings systems on my machines for the past few years.

It's not necessarily the easy way to do things. It is the way I first learned and the way that I'm most comfortable with using. I'm posting it here, as I believe it may be helpful to some Linux Explorers out there. This tutorial is based on GRUB Legacy. I do not use the new GRUB2 on my machines.

Here we go...

I have multiple drives on my system, so multi-booting becomes a bit more interesting. Currently, I have three hard drives installed. They are /dev/sda, /dev/sdb, and /dev/sdc. We won't concern ourselves at all with /dev/sdc because it is primarily used as a common storage/backup drive. My operating systems are installed on /dev/sda and /dev/sdb.

I use /dev/sda (1st boot device in my BIOS) as the drive that has my primary operating system and my secondary operating system on it. I break my drives down into numerous partitions because I always install GNU/Linux operating systems on at least two partitions; /(root) and /home. I also have a common /swap partition on each drive that I plan on installing GNU/Linux distributions on.

My /dev/sda partitions look like this:

/dev/sda1   *       16065    51215219    25599577+  83  Linux <-- Slackware /(root)
/dev/sda2        51247350   153645659    51199155   83  Linux <-- Slackware /home
/dev/sda3       153661725   488392064   167365170    5  Extended
/dev/sda5       153661788   204860879    25599546   83  Linux <-- Arch /(root)
/dev/sda6       204877008   307275254    51199123+  83  Linux <-- Arch /home
/dev/sda7       307307448   311403959     2048256   82  Linux swap / Solaris
/dev/sda8       311420088   488392064    88485988+  83  Linux <-- Archives

My /dev/sdb partitions look like this:

/dev/sdb1   *       16384    51216383    25600000    7  HPFS/NTFS/exFAT <-- MS Windows XP
/dev/sdb2        51232768   102432767    25600000    7  HPFS/NTFS/exFAT <-- MS Windows Programs
/dev/sdb3       102453181   488270159   192908489+   5  Extended
/dev/sdb5       102453183   106550639     2048728+  82  Linux swap / Solaris
/dev/sdb6       106565823   137289599    15361888+  83  Linux <-- CentOS tester 1 /(root)
/dev/sdb7       137304783   188501039    25598128+  83  Linux <-- CentOS tester 1 /home
/dev/sdb8       188516223   219239999    15361888+  83  Linux <-- Foresight tester 2 /(root)
/dev/sdb9       219255183   270451439    25598128+  83  Linux <-- Foresight tester 2 /home
/dev/sdb10      270466623   301190399    15361888+  83  Linux <-- Debian tester 3 /(root)
/dev/sdb11      301205583   352401839    25598128+  83  Linux <-- Debian tester 3 /home
/dev/sdb12      352417023   383140799    15361888+  83  Linux <-- vacant tester 4 /(root)
/dev/sdb13      383155983   434352239    25598128+  83  Linux <-- vacant tester 5 /home
/dev/sdb14      434367423   488270159    26951368+  83  Linux <-- common storage

You get the above information on your drives using the fdisk -l command as root from the command line.

Alright then, let's say that I now want to install Fedora Core Linux on my tester 4 partitions of /dev/sdb. Here's how I would do that step-by-step:

1) Begin the Fedora installation setting /dev/sdb5 as swap, /dev/sb12 as /(root), and /dev/sdb13 as the /home partition from Fedora's installer.

2) When the Anaconda installer reaches the point where it asks where I want to install the GRUB bootloader, I choose to SKIP installation of GRUB.

3) Once the install is finished, I reboot my main operating system (Slackware) and from the command line I mount the newly installed Fedora /(root) partition:

root_Slackware/home/vtel57:# mount /dev/sdb12 /mnt/tmp

*Note: I have a /mnt/tmp directory in my Slackware. If you don't have a /mnt/tmp, just mount in /mnt. You'll be fine.

4) I list the contents of the Fedora /boot directory:

root_Slackware/home/vtel57:# ls /mnt/tmp/boot

5) I copy down the vmlinuz and initrd information. You'll be looking for the vmlinuz-<kernel version> and the initrd-<kernel version>.img files specifically. You'll need that information for the next step.

6) I edit my /boot/grub/menu.lst file to add the new Fedora Core entry. Note: my MBR-controlling GRUB is in my secondary OS, Arch Linux. I can still mount and modify it from within Slackware, though.

root_Slackware/home/vtel57:# mount /dev/sda5 /mnt/tmp

root_Slackware/home/vtel57:# vim /mnt/tmp/boot/grub/menu.lst

I'll add this entry to the file:

# Fedora Core

title          fedora (t4)

root         (hd1,11)

kernel     /boot/vmlinuz-<kernel version> root=/dev/sdb12 ro

initrd       /boot/vmlinuz-<kernel version>.img

7) I reboot and choose "fedora (t4)" from the GRUB menu to boot my new Fedora installation.

That's it, folks. Straightforward, but not necessary the easiest way to do this. That's the beauty of GNU/Linux. You can do it your way.

Have fun!

~Eric

P.S. I'm still working on the next shell scripting lesson. It's going to be about variables and parameters, a necessary lesson for further BASH learning. Unfortunately, it's also kinda' complicated, so it's taking me a bit to figure out how to formulate a lesson and still stay loyal to my primary goal here... keeping it as simple as possible. Stay tuned...

*Originally published on my Nocturnal Slacker v1.0 blog at Wordpress.com
  

 

 

Accessing Amazon EC2 Instance information from the command line using curl

If you use Amazon Web Services EC2 for virtualising your infrastructure, you may find that once you have a few instances started, that it may be hard (especially if you aren't using a configuration management tool) to trace back 'which machine belongs to what security group?' or 'which AMI did I use to bring up this instance?.'

 

Well theres a few quick tricks you can use to get some info out of your running instances. To do this you need to access the instances meta-data, and this is available simply by using 'Curl' from your running Linux instance, as follows:

 

'curl http://169.254.169.254/latest/meta-data/<metadata-object>'

 

here are some of the metadata objects:

ami-launch-index

ami-manifest-path

block-device-mapping/

hostname

instance-action

instance-id

instance-type

kernel-id

local-hostname

local-ipv4

placement/

profile

public-hostname

public-ipv4

public-keys/

reservation-id

security-groups

 

ami-manifest-path will tell you from where on AWS the AMI (the Amazon Machine Image for the linux virtual machine) was launched. If you rolled/composed your own AMI this helps you match up which Bucket on S3 relates to your AMI.

 

for example:curl http://169.254.169.254/latest/meta-data/ami-manifest-path

 

 

public-ipv4 is the world-facing IP address of the running virtual machine.

 

If your not sure from looking at the AWS Dashboard (or dont have access to it) you can run:

 

curl http://169.254.169.254/latest/meta-data/instance-id

 

this will help you make sure if you want to terminate an instance that you kill off the correct one.

 

Its easy to experiment with, and the fact that you use curl to access the metadata information, it means that its also something thats pretty easy to compose a shell script for commonly needed tasks.

Hope someone finds this helpful.

 

openSUSE Weekly News 172 is out!

We are pleased to announce our openSUSE Weekly News #172

In this Issue:

  • Evergreen needs you
  • Evergreen & Tumbleweed status update
  • First openSUSE Conference 2011 Program Commitee Meeting
  • Installing latest Intel graphics driver to openSUSE 11.4
  • and many more ...

You can download it there:

We hope you enjoy the reading :-)

If you want to help us collecting interesting articles for the openSUSE Weekly News, so you can all your stuff into our new ietherpad: http://os-news.ietherpad.com/2.

Found Bugs? Please place it in our Bugtracker: http://developer.berlios.de/bugs/?group_id=12095

Features, Ideas and Improvements can placed in our Featuretracker: http://developer.berlios.de/feature/?group_id=12095

Older content can be found there.

Flattr this

 

 
Page 19 of 133

Who we are ?

The Linux Foundation is a non-profit consortium dedicated to the growth of Linux.

More About the foundation...

Frequent Questions

Join / Linux Training / Board