Sun Microsystems is a great company anyway, they make outstanding hardware and deliver a rock solid operating system. Add to that all of the stuff they open source to the public and it just gets better. Now they have announced that their latest chip, the T2 or Niagra 2 has also been open sourced. This means that anyone can get the code, plans, schematics, etc. and make their own … for free. Think about that for a second. Let’s say you are a device maker, some mobile gadget, and you need a CPU to work with. Would you rather use something like the T2, which is unmatched in capabilities for free? Or pay a few million for an Itanium chip? Yeah, me too. I’ll take the Sun chip and run before they change their mind. They have opened other chips too, like the T1, and software like Java and Solaris. Good stuff as far as I am concerned.
Archive for the ‘UNIX’ Category
12
Sun Microsystems Opens the T2
21
Bash script tip, cutting from variables
Ok, here is a quick tip that has come in handy quite a few times in my days writing shell scripts, for example in bash. Let’s say, for whatever reason, you need to chop off the end of a string (like a variable). Chopping the beginning is easy, just use the cut command, but in order to chop the end you have to know how long the string is so you can tell it where to start. In this example, we are going to us the wc command to figure out how long the string is, and then subtract 1 to cut the last character. You can subtract however many you want depending on how many characters you want to cut. Check it out … Read the rest of this entry »
20
Linux running in Solaris
Holy Virtualization batman, it looks like Sun Microsystems is improving it’s containers sub system and will now allow users to run unmodified Red Hat and CentOS linux under a Solaris container or zone! That’s awesome! I have already become a huge fan of Solaris containers, and now with it being able to support Linux, that’s a great boost to an already wonderful technology. Check out the article at Solaris Central. In case anyone missed it, I posted a script a while back for creating zones in Solaris 10. I’ll have to modify it (if need be) when the latest version comes out to support Linux. Enjoy!
9
New article on setting up sendmail
I have a new article up that I have written and dropped off into the Library about configuring sendmail on Linux. Although it should work on most any distribution that will run sendmail even if some file locations may change. Have a look, check it out, send me some feedback if you love it, hate it, or if I made a boo boo somewhere. As always, I hope you find it useful. Thanks!
25
Create a file of arbitrary size
Have you ever needed to create a file of a specific size? Not where the contents are anything specific, but you just need a file that is whatever size so you can test disk I/O or network transfer speed or whatever it is you want to test. For whatever reason, I have found it very handy to be able to create these test files when needed, so I thought I would pass along some tips to that end. Here are some ways you can accomplish this with Solaris and Linux.
20
Working with cpio files
Have you ever downloaded a cpio file and wondered what the heck you were going to to with it? I get them from Oracle all the time, and the first time I downloaded one I wasn’t sure what to make of it. In the end, I found that working with cpio files is a breeze, so I thought I would pass on some information that might help.
Ok, just what is a cpio file? A cpio file is an archive, and it is a concatenation of one or more files. Each file in the collection contains a header optionally followed by file contents as indicated in the header. The end of the archive is indicated by another header describing an empty file named TRAILER. There are two types of cpio archives, differing only in the style of the header. ASCII archives have totally printable header information, so, if the files being archived are also ASCII files, the whole archive is ASCII. By default though, cpio writes archives with binary headers.
How do we work with these archive files? Easy. Here is an example, say you download a gzipped cpio file:
- First, download filename.cpio.gz and use gzip to uncompress.
- Then use cat filename.cpio | cpio -icd to extract to contents.
There you go, when you are done, the contents of the cpio file should be extracted to where ever you put the cpio file and ran the command. If you want to create an archive, you can pass a file list, like with find to the cpio command and have it create an archive, much like tar does. In my own experience, I prefer tar, but if you have cpio and don’t have tar, it’s better than nothing! Check out this page for more details, a nice article from Linux Journal.
