Tiny Core Linux

If you want to go back to those great old days of really lightweight Linux, give Tiny Core Linux a try and relive the joy of a bare-bones system.

where yyy is the subdirectory name.

This gives you a really fast basic desktop, which is fine for everyday use. But, what if you want to adjust the distribution for some special case? To figure out how you can personalize it, let's take a step back and look at how Tiny Core is put together and how it works. Then you'll see how to change the system to suit your application.

The core part of the system is stored in a compressed filesystem that gets copied to RAM. Any extra applications are mounted from wherever they are stored as loopback devices, by default. They can be selected to be actually copied to RAM along with the core system, if you prefer. The advantage of this “run from RAM” system is that once the system has finished booting, you can remove the storage media.

In the first case, let's assume you have the system booting from a USB device that you don't need to remove. Then, you have two options on how to set up the system. The first, mount mode, is to create a directory called tce on the USB device. In this directory, you can dump packages for all the applications you want to have available. These then are mounted as loopback devices. You can use a utility called appsaudit to maintain those packages. You have the choice of having those packages mounted at boot time, or you can have them mounted “on demand” (Figure 4). The other option is called copy mode. In copy mode, Tiny Core actually takes the contents of the package files and copies them all into RAM. This costs a bit more in boot time, but then the entire system is, again, running from RAM, so you get the expected speed-up once everything boots. You actually can control which packages are copied into RAM on an individual basis through the configuration file copy2fs.lst. The system can use this file to decide what is copied and what is mounted.

Figure 4. Maintaining your installed packages is made simpler with a GUI application.

These aren't the only methods available if you want to make a tailored distribution. Because Tiny Core is under the GPL, you can grab the source code and mess around as much as you please. You actually can just remaster the ISO to add in any extra packages you need for your application. In the ISO, there is a gzipped cpio archive named tinycore.gz. This file contains the core filesystem that is mounted in RAM when Tiny Core boots. You can do this work on any Linux box or even from within Tiny Core. If you want to do it in Tiny Core, you need to install a few extra packages before you start: advcomp.tcz and mkisofs-tools.tcz. Once you have all the tools you'll need, you can mount the ISO image:

sudo mount tinycore.iso /mnt -o loop,ro

where /mnt is the directory to which you want to mount. You also need a directory into which you can extract the Tiny Core filesystem, which for this piece, let's call it /temp/extract. To get the files, you need to execute the following:

cp -a /mnt/boot /temp
cd /temp/extract
zcat /temp/boot/tinycore.gz | sudo cpio -i -H newc -d

Once this command is done, you can go ahead and change files, add new ones or delete others. This way, you can add extra binaries (such as for a point-of-sale application) directly as part of the system. If you want to be able to handle special hardware, where you'll need a new kernel module, you can add it to the filesystem. But, then you'll need to run this:

sudo depmod -b /temp/extract

You also may need to add new shared libraries to provide support for any new binaries you install. If you do, run this:

sudo ldconfig -r /temp/extract

Once you've finished creating a personalized filesystem for Tiny Core, you need to get it ready to use. The first step is to pack the filesystem back up into a gzipped cpio archive. Run the commands:

cd /temp/extract find | sudo cpio -o -H newc | 
 ↪gzip -2 > /temp/tinycore.gz
cd ..  advdef -z4 tinycore.gz

This will give you a brand-spanking-new core file. If you are using a system other than a CD from which to boot (like some form of hard drive), you simply need to copy tinycore.gz and the kernel to that device.

If you want to create a new ISO image that you can use over and over again, execute the following commands:

cd /temp
mv tinycore.gz boot
mkdir newiso
mv boot newiso
mkisofs -l -J -R -V TC-custom -no-emul-boot \
   -boot-load-size 4 -boot-info-table \
   -b boot/isolinux/isolinux.bin \
   -c boot/isolinux/boot.cat -o TC-remastered.iso newiso
rm -rf newiso

You now have a nice new ISO that you can put to work.

This kind of task happens often enough that the Tiny Core team has put together a GUI application that helps simplify these steps called ezremaster. Install it using the AppBrowser. This way, all the required dependencies also will be installed. You also need either to have the ISO available or a CD mounted. Once you've done all of these steps, open up a terminal and run ezremaster from the command line, and you should see what's shown in Figure 5. Here you can point it to the locations it needs, and you should end up with what's shown in Figure 6. From there, you can set all kinds of options to customize your ISO image. The sections available are:

  • Boot codes.

  • Display settings and mydata.tgz backup.

  • Security settings and users.

  • Which services would you like enabled?

  • Network settings.

  • Window manager, core elements and Xorg settings.

  • ISOLINUX settings and 64-bit kernel.

  • Startup and shutdown scripts.

  • Extension installation.

Figure 5. The first step when using ezremaster is setting paths for the source files and a working directory.

Figure 6. You can set default boot codes to save you extra typing on each boot.

Once you have finished all of these steps, move on to “Remaster step #1”, where the filesystem for the new ISO is created. Once that step is done, move on to the last step, “Remaster step #2”, where the actual ISO image is created. It ends up in the temporary directory you defined in the first screen. Now you're ready to deploy your awesome customized Linux on the world.

Be sure to check out the Tiny Core Web site and Wiki for more information (www.tinycorelinux.com). There is also a very active forum at the main site where people always are happy to answer questions. Hopefully, this project can give you a quick start for generating your own custom distributions for your smaller projects.

When Joey Bernard isn't debugging scientific code or sorting out problems on the clusters at the university, he's working on refinishing furniture or playing with his boys in the backyard. He might call himself a renaissance man, but that sounds a little too presumptuous. Just call him a well-rounded geek.


Joey Bernard has a background in both physics and computer science. This serves him well in his day job as a computational research consultant at the University of New Brunswick. He also teaches computational physics and parallel programming.


Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

thin clients

Anonymous's picture

I would suggest searching eBay for Neoware clients CA2 and higher. Either using the SiS or Via CPUs. I am running TinyCore on one from a USB stick. Research the CPUs used, generally the higher the CA# the faster the chipset. Some later models come with DVI connectors as well as VGA.

Neoware was bought by HP and their leases are ending so alot of very good equipment is coming to eBay :)

Also check out http://www.parkytowers.me.uk David has been doing this for a while and is a great resource for those wishing to fiddle with linux on thin client cast offs. He built one webserver (middle of the pack specs) from which he was able to get 1000 pages (average 9 KB per page) served in under 9 seconds. Latentcy of less than 0.2 sec per query.

Hey, these devices burn less than 25 watts per hour of electrical power. That works out to less than 6/10th Kilowatt/Hr per day. For me that is less than 10¢ per day cost to operate. Nice for a light weight web server.

What about floppies?

Macrorodent's picture

This like most mini distros these days boot off CD-ROM or USB. But that leaves old computers that cannot boot from CD-ROM (even though they usually have one) and have no USB ports out in the cold. I have one such machine, a pretty Pentium laptop. The last Linux I could get to work on it was CentOS 3, which is no longer updated. Anyone know of an up-to-date mini distro where the installation could at least be initiated from a floppy?

If BIOS won't boot CD, try a custom boot loader

Anonymous's picture

Try the PLoP boot loader if you're having trouble booting from anything other than floppy. As long as your CD drive is ATA, it should work.

I've been using it to boot from USB "thumb drives" on machines that refuse to recognize them as bootable media. For network, I use syslinux to launch iPXE.

I haven't yet run into any computer that I couldn't find some way to boot as I wanted...

the problem "no cdrom/no

Anonymous's picture

the problem "no cdrom/no floppy" is solved from MANY years, using network bootstrap.
Basically two modern methods: or using software already available in motherboard BIOS o PCI ethernet BIOS (named PXE) or using a floppy/hdisk/cdrom/usb that load PXE. the size is few tens of kilobytes ,so no problem.

Beside the point

Macrorodent's picture

Old computers may not have a network card, and certainly have no PXE software onboard. In the laptop I am talking about, the only way to get network is either PPP via the RS-232, or with a plug-in PCMCIA ethernet card. I have one, but it is useless without an OS running on the box that supports PCMCIA and the card in question.
As this machine has a floppy, and a working CD-ROM (albeit not bootable), the easist bootstrap is the way CentOS supported up to version 3 (and other old distros did as well): Load the installer from the floppy, which then can access the CD-ROM. I guess installers have grown so big they don't fit on a floppy these days, and distro authors see no point even trying (no wonder, it would be a wasted effort except for a few "museum pieces" like mine). Oh well, it may be I need to create my own old computer distro (like I had any time for such activities these days :-( ).

pity that

istok's picture

interesting distro, very exciting concept, but could never test it properly because fonts render so badly i start crying after 15 minutes.

I'm still a big fan of

Mozai's picture

I'm still a big fan of Slax.org. Loads into RAM, and I can do package management on the image without having to do it from the inside.

People of a certain age may

Anonymous's picture

People of a certain age may remember projects like Tom's root/boot, or muLinux.
Stop trying to make me feel old, I'm only 21!

Maybe Nostalgia, although Maybe Not

fabulonee's picture

Nifty LinuxJournal article.

Although a biggie negative I've had a bit 'o severe difficulty with (even impossibility) is getting that darned TC INSTALLED to hd!!
Sure there are all those cheat codes, .tgz apps and persistent-storage settings, but when push comes to shove and you're ready to to finally get TC bootable, ON YOUR HARD DRIVE, via grub, you're basically 50 5cr3w3d.
Even though DSL is Shingledecker-archaic, it just puts TC IN THE DUST in this regard!!!
Even Puppy's Frugal Install is a walk in the park compared to a full TC install.....Shame on those TC developers (excusing Shingledecker for his AWESOME creations!!)

Slitaz is Also Good

metalx2000's picture

I like Tiny Core, but I find that Slitaz is a bit easier to use and it is just as light weight. Slitaz's main release is 30MB, but comes with a lot more installed by default then Tiny Core. Slitaz also has a 8MB commandline version, and a 15MB JustX version. As well as other community versions.

Slitaz makes it extremely easy to remaster and install to a hard drive.
If you like Tiny Core, I would suggest having a look at Slitaz.

Everything you ever need to know about Open-Source Software.

I tested Slitaz too, several

Anonymous's picture

I tested Slitaz too, several months ago. Compared to the difficulties for setup on hdd I had with TinyCore, the Sltiaz distro was a breeze. For a preselected set of packages of install I've ended with 300 MB used space at Slitaz, compared to 190M at TinyCore. Not a big deal of a difference. And while TinyCore wins the prize for a proof of concept how small a distro can be with its 10Mb, Slitaz is much more useful with its initial 30Mb on cd image.

Not a big deal of difference,

Anonymous's picture

Not a big deal of difference, I agree. However, 63% is a large difference. ;)

Not merely nostalgia!

Sobac's picture

Tiny Core is a fine, superior follow-on to Damn Small Linux and is small enough to fit on thin clients. There are heaps of used thin clients available cheap on Ebay but the vast majority of Linux distros are far too fat to fit.

Instead of an individual custom image built elsewhere then installed, Tiny Core can be installed and configured on the hardware. The recent kernel is a Good Thing.

thin clients

Michael Shigorin's picture

There's at least one modern LTSP distribution successfully booting up diskless thin clients with a Pentium and 16M RAM: http://en.altlinux.org/LTSP

thin clients

Anonymous's picture

@Sobac I have been fascinated by the prospect of running linux (embedded?) on thin clients... just to explore as a hobby. Can you point me to some cheap items I can look for on ebay? Any good resources you can point me to on the internet?


For thin clients, you should

Gavin's picture

For thin clients, you should keep up to date on Raspberry Pi, which will be an ultra-low-cost computer-on-a-stick.

Raspberry Pi is arm based,

Anonymous's picture

Raspberry Pi is arm based, tinycore wont work on it

Free Dummies Books
Continuous Engineering


  • What continuous engineering is
  • How to continuously improve complex product designs
  • How to anticipate and respond to markets and clients
  • How to get the most out of your engineering resources

Get your free book now

Sponsored by IBM

Free Dummies Books
Service Virtualization

Learn to:

  • Define service virtualization
  • Select the most beneficial services to virtualize
  • Improve your traditional approach to testing
  • Deliver higher-quality software faster

Get your free book now

Sponsored by IBM