BARBELITH underground
 

Subcultural engagement for the 21st Century...
Barbelith is a new kind of community (find out more)...
You can login or register.


There's something about UNIX

 
 
Saturn's nod
12:47 / 01.08.06
How many other operating systems are still the business 30 years after they were launched? I've got to admit that I harbour a personal passion for unix-y systems, and part of that is to do with the apparently infinite depth of customisation available.

What is it about unix that makes it so lovely?

Is it an illusion? Has the basic architecture actually changed a lot over the past 30 years but it's passed me by because I know next to nothing about computing history?
 
 
Unencumbered
07:53 / 06.08.06
This is a difficult one. I think one of the great things with UNIX is that is just *works*. The basic philosophy is simple but allows the system to expand in all manner of interesting directions. Exactly what you want in an operating system.
 
 
cfm
10:49 / 06.08.06
The obvious ones: uptime. Reliability. Varying kinds and degrees of free-ness and freedom. General lack of bloat (no GUI unless you need one).

Also, the availability of small freebies that do one thing and do it extremely well.

I was writing an internet backup script for someone in my family the other day, from our home server over to Strongspace via rsync, and stumbled across a bandwidth-throttling utility called wshaper. It's less portable than other UNIX utilities, since it's dependent on the tc command of the Linux kernel, but there are a lot of Linux distributions...

I wonder how, or whether, I would have found a similar utility for Windows. Things like rsync, BASH, and SSH make complicated tasks relatively simple.
 
 
Saturn's nod
10:10 / 07.08.06
Right. I love the small tools thing. I have a small love affair with sed at the moment: I love that I can do so many useful operations with a neat and tiny tool. Grep similarly.
 
 
Ticker
17:52 / 08.08.06
only Unix has daemons. I mean come on how cool is that?

Okay and the ability to allocate system resources with a fine layer of control and gracefully compile applications from source to custom tailor everything down to a lean sexy machine.

Sure sometimes compiling software feels like an esoteric goose chase as you locate very dependant required piece and finally you end up with the Taj Mahal made out of popsicle sticks. But damn you made it and look at the thing purr!

vi is the sexiest badass tool in the box. though sed and find in tandem do really really great time saving tricks.



Tip:
To remove the ^M characters at the end of all lines in vi, use:


:%s/^V^M//g

The ^v is a CONTROL-V character and ^m is a CONTROL-M. When you type this, it will look like this:


:%s/^M//g

In UNIX, you can escape a control character by preceeding it with a CONTROL-V. The :%s is a basic search and replace command in vi. It tells vi to replace the regular expression between the first and second slashes (^M) with the text between the second and third slashes (nothing in this case). The g at the end directs vi to search and replace globally (all occurrences).
 
 
Ticker
17:27 / 10.08.06
Yo behold the sexy groove of Nessus Security Scanner if you haven't already.

I've been addicted to it for years and it has often saved my ass.
You can scan any 'puter with it. Though to avoid being a DOS ass hat, get permission first.
 
 
Happy Dave Has Left
12:13 / 18.08.06
I've installed Ubuntu Linux on an old iMac, and a lot of fun it was too. However, when I'm fiddling around in the command line, I'm often typing things by rote from forum posts, and not really understanding a) what the commands are actually doing and b) what the commands actually mean. It's like mystical incatations to some sort of electronic God. Are there any decent resources out there that take you from being a complete newbie (i.e., what does ls do?) to grepping and SSHing with the best of them? Cos I'm buggered if I can find any.
 
 
Ticker
17:29 / 18.08.06
BEHOLD! THAT FOR WHICH YOU SEEK!!!

Unix in a Nutshell

it's a book, buy it, read it, learn what RTFM really means.
Seriously it's a great book.

Or even the wee gentle:

Learning the Unix Operating System
 
 
Rayvern
08:37 / 08.09.06
I think this explains what is 'wonderful' about Unix.

A different outlook on Unix

(Please note, my putting up this link does not mean I hold to all the opinions contained with in the document. Just that I thought it was an interesting take on Unix).
 
 
Saturn's nod
14:39 / 08.09.06
Hmm, I'd love to read it but I'm not getting the pdf opening right from your link, Rayvern, which might be some kind of $pdf_reader/mozilla/linux specialness I guess. Everyone else getting it okay?

Ecstatic Dave, I hope you're getting on well. Remember "Google is your friend": whereas you used to have to use the "man" (manual) command to look up info, now they've built a whole intern3ts to archive every tech discussion ever. I just type in the stuff I want to know about, as specifically as possible, and I often find something useful. Apologies if that's way patronising/over-obvious.

That links to the other thing I love about unix: the 'infinite depth' I mentioned in passing in the topic post. At first to me it looked like it was impossible to know anything significant about unix because everything about it could be hacked - let's call it the "I have no idea how to write my own drivers therefore I know nothing much about unix" fallacy. But if instead you look at it as a big heap of clever clay, which you can shape and mould any bit you learn how to work with - great! It's no longer a bottomless pit, but a lot of fun instead. And cos everyone knows how to hack one corner of it or another, community's the way to go, and the lovely intern3ts have stored many of the discussions.

My third tip's Debian Women and similar projects: (not only for women - lots of men there too), and I think it's more friendly & less cockwaving than the average techy hangout because composed of people who actually want more women involved in GNU/Linux.
 
 
Saturn's nod
15:22 / 08.09.06
Ah, got it now - was a $pdf_reader issue. Thanks Rayvern. It's a 30page ebook called "the unix-haters handbook". And it's got a foreword written by a real programmer (that's as far as I've got). W00t.
 
 
ORA ORA ORA ORAAAA!!
14:00 / 10.09.06
I really like Linux. But I never boot into it these days.

It's mostly fear of the unknown, I guess. Linux puts me back into new user territory, and while I can generally munge my way around in any computer system, the fact that I know I'm not doing it in a particularly efficient way, and that I'll have to look things up if I come up against anything complicated just kind of turns me off. If I came into linux cold, without knowing anything about computers, I don't think I'd have any problems with it, but because I know how to do damn near anything on other platforms, and I know how much more you can do on a well-turned *nix machine, the wall of knowledge seems insurmountable.

so, basically, can't write drivers, don't know unix.

I do really like the 'devices (and etc) as files' metaphor, though. /dev/null has got to be one of the most useful shortcuts ever made.
 
 
petunia
19:30 / 14.03.07
I'm running OSX as my main computer, which is technically Unix with pretty added stuff. I also run Ubuntu Linux on my download/server box.

After having used the CL for various things (mostly copy-pasted fixes from the ubuntu fora) on the Linux box, i have decided to brave the OS X terminal and teach myself How Computers Work.

So far, I have learnd to use sftp to up/download stuff from my webspace. I have learned to use rsync to backup stuff onto said space. I have run a couple of traceroutes to find out why these things ran so slow (turns out distance still exists in the real world...) and i have even managed to install my own working version of Amarok, which i think is much nicer than iTunes. (the last one was a bit of a cheap, using Fink package manager for most of it, but i did get to compile from source, which was exciting!)

For me, using Unix is tyed up with a certain geeky aesthetic. I can do most of these things with handy GUIs, but command-line fun makes it feel like i'm doing it properly. Each little thing i learn to do with the CL gives me a glimpse behind what is going on it all of my windowed apps. It's starting to give me an appreciation for the great amount of work that goes into every computer program. The fact that a lot of these programs are created free of charge is pretty amazing.

I'm saving up to get the nutshell guide and i'm making a list of things i want to do in Unix, so that i may become teh l33t Haxor (is that how it's spelt?)
 
 
Ticker
19:53 / 14.03.07
yay for you!

hackers are teh lame. Teh coders and teh SysAdmin are teh root.

I'M IN UR BOX

RUNNING AS ROOT

Some folks think you're not hardcore until you give up GUI email clients and embrace the power of pure shell. I personally think anyone who looks through the man pages first before calling for help is on the right path. Don't worry about being cool just have fun learning.

Of course I occassionally consider getting RTFM tattoo'd on certain less visible parts of my body but then I use vi as my editor (which makes me a certain form of crazy).
 
 
otto628
02:45 / 16.03.07
I cut my teeth on Unix (SCO Unix) in my Military days back in 1994....worked with HP-UX, Solaris, and RedHat for many years to follow.

The old analogy of operating systems versus airplanes is perfect to describe Unix....I'm gonna paraphrase it here:

With Unix, You get on the runway with all your airplane parts and your tools.

It takes a lot longer to put the airplane together, but once you get it running.....it keeps running....

As opposed to Microsoft, which would have it's flagship Aircraft's maiden voyage preceded by a huge press conference and gala, star studded party.

Plush seats, plush carpeting...champagne and caviar served to all the passengers.

The plane takes off, reaches altitutde, and, for no reason......explodes in midair, killing everyone on board.

I forget how the analogy for Apple/MAC went...it was pretty good too..


But back to the point.........Unix let's you get under the hood....for everything....there is no componenet of unix that cannot be taken apart and scrutinized....
 
 
Mirror
22:08 / 07.04.07
One of the things I absolutely love about Unix is that it's possible to do so incredibly much without using a mouse. For a power user, the command line is many, many times as efficient as a point-and-click interface for just about any given task.

Point-and-click interfaces are easy and (if they're done well) intuitive to learn, but they're slow to use both the first time you use them and the hundredth time. Command line interfaces are harder to learn, require you to remember commands and switches and such, but they're easy to script which reduces what you have to remember, and for things that you do regularly they are maximally efficient because you either script them, or the switches you use become hard-wired into your muscle memory.

I'm a fairly heavy VI user, to the point that I get irritated any time I have to use a text entry interface that doesn't have VI keybindings. What do you mean I have to take my fingers off the home row of the keyboard to move my cursor around???
 
 
Red Concrete
00:53 / 08.04.07
What do you mean I have to take my fingers off the home row of the keyboard to move my cursor around???

Hehe, years of playing Rogue will do that to you
 
 
Red Concrete
23:22 / 09.04.07
Ahem! Sorry... I've been playing too much Rogue.

After years of prevaricating, you've all helped convince me to install Linux on my home computer. Five hours later, success!! It's now dual-booting Win Xp and Fedora core 6, and I have an extra 2 Gig of memory en route from Crucial.

My reason for this insanity? I've been using Linux in work for the past year now, and really enjoying grep, shell scripting, even sed and awk, and have finally started writing decent sized perl scripts too. These things are great for handling large datasets, which in Windows would need a spreadsheet, and would still need to be broken into manageable chunks and dealt with separately.

So now with my work computer, plus the work server, and my home computer I will get a lot more done, faster. I will be able to program at home in a much nicer environment than the SSH window. And I hope to increase by a huge amount my *NIX skills, and my understanding of The Computer.
 
 
Bamba
18:58 / 16.04.07
Disclaimer: I can do the most basic operations in UNIX but I really don't know shit about it.

So, I've been reading the eBook Rayvern linked to in idle moments and was surprised by, well, pretty much all of it. The picture it paints is one of a creaky OS held together by chewing gum and bits of string. It talks of slowly accreted functionality that was hacked together rather than designed, of sloppy programming and strange assumptions in the code, of file systems that behave in weird ways and eat your files at the drop of the hat. All of which is obviously utterly at odds with everything else I hear about UNIX. We hear only about it's speed, it's reliability, it's security, etc.

Now, I know the book is hella old so, has everything in there been fixed in intervening years? Or is the author just completely full of shit (or at least exaggerating his ass off)? Or some combination of the two?

As an example of the kind of thing I'm talking about, here's an extract from the text about disk usage:

The Unix file system slows down as the disk fills up. Push disk usage much past 90%, and you’ll grind your computer to a halt.

The Unix solution takes a page from any good politician and fakes the numbers. Unix’s df command is rigged so that a disk that is 90% filled gets reported as “100%,” 80% gets reported as being “91%” full, and so forth.

There is a twist if you happen to be the superuser—or a daemon running as root (which is usually the case anyway). In this case, Unix goes ahead and lets you write out files, even though it kills performance. So when you have that disk with 100MB free and the superuser tries to put out 50MB of new files on the disk, raising it to 950 MB, the disk will be at “105% capacity.”


WTF? The PS command actively lies to people to try and keep the system running? Utter madness!

Was UNIX ever really so bizarre? And has all that kind of nonsense been nailed down over the years? When the author describes the kind of environment that UNIX grew up in it all makes a lot of sense* that it would be sort of 'bodged' together but, as I say, that image of it's so contradictory of it's current reputation that I'm struggling to believe that's ever been the case.

*University lab hackers throwing shit together to solve whatever problem was right in front of them at the time with scant regard for future usage, while various organisations created different versions that conflicted and fought with each other, all the while claiming their's was the best.
 
 
jmw
18:54 / 24.04.07
I wouldn't like to comment on the specific passage you quote (because I don't know) but a lot of the Unix Haters Handbook is true and lots at least more rings true. Read about the sections about Silicon Graphics and X11.

None if which is to say that other systems aren't held together with different bits of string and chewing gum in other places.
 
 
Ticker
18:57 / 24.04.07
true but chkconfig is a lovely gift from SGI.
 
 
Ticker
18:59 / 24.04.07
oh and a question, while I'm thinking of it.

fsck

I always say 'f-s-check' but my old junior admin said 'f-suck'.
What about you?
 
 
Red Concrete
11:27 / 26.04.07
I say fisck. But I rarely have to say it...
 
 
Saturn's nod
12:30 / 26.04.07
Yeah I say 'f-s-check' too, although I know what someone means if they say it 'fisk'. Not heard 'f-suck' before but it's kind of amusing.
 
 
Ticker
13:26 / 26.04.07
huh never heard fisk before.

f-suck made me laugh too and at first I thought it was just the kiddo but the rest of the department said it that way as well.
 
 
jmw
15:24 / 28.04.07
Re SGI, yes, as is XFS. Actually, the state of SGI today saddens me.
 
 
cusm
16:07 / 29.04.07
Its a programmers OS. You have complete control, transparency, a wide public support base, and its free. And it'll run on a 486 3mMhz with 16mb of RAM. There's a version of FreeBSD which can, in fact run from a floppy. Now that's efficiency.

But really, when your shell interface is basicly C, you run it all via short and powerfuls scripts tailored to exactly how your idiosyncratic brain prefers to see things done. That feeling of power is I think itself addictive and seductive. You really just have to be a programmer to understand. The box does exactly what I SAY. If it breaks, its MY PROBLEM, not some idiot in Redmond I can blame.

And there's the arcane joy of tools like sed, awk, and grep. If you know the language, there is practicly no form of text processing you can not accomplish within two lines of regular expression code that looks like modem noise.
 
 
Happy Dave Has Left
15:40 / 07.08.07
Hello UNIXians.

Though I doubt most of you will need this, thought you might like to keep this *nix cheatsheet handy. It's pretty fab.
 
 
lille christina
18:50 / 15.08.07
Meow! *Currently installing Debian on a Hewlett Peckard Pavilion...for the first time*

Quite a bit excited...
 
 
Nocturne
17:36 / 27.10.07
Recently installed Ubuntu Linux for the first time. I think I'm just excited about finding out what happens when a batch of people get together and decide to make an OS. What will this OS end up looking like?

Installation of the OS went smoothly. Trying to install other things is a bit of a learning curve. People on the Ubuntu forums frequently talk of trying to make it an easy distribution for anyone to use, but I don't think it's quite made it yet.

I'm still having fun with it though. My main reason for using it was that I wanted to learn more about, well, anything computer related. Why did you decide to try *nix?
 
 
petunia
18:41 / 27.10.07
Why did you decide to try *nix?

Originally because i had an oooold pc which wasn't coping too well with windows, and because i fancied trying it out. I got xubuntu and installed it and was very happy. This was about the same time as i got a new ibook (yeah, macs are technically *nix, but it doesn't count for the most part), so i wasn't using ubuntu as a daily thing, but more as a downloader/fileserver.

Since then, i've used it mainly for that task on different pcs. It's nice and sturdy - you can leave it running for weeks without worrying about it, and there's something pleasingly hands-on about the whole thing, though i'll agree with you that it's a somewhat difficult learning curve for someone coming from windows or os x - using the command line s still pretty much a necessity, even in as user-friendly a system as ubuntu.

Considering Ubtuntu has only been around for 3 years, i'd say they're doing very well at making a system which 'just works' - i did a fresh install of the latest version ('Gutsy Gibbon' - not a fan of the alliterated animal appellations...) and it ran absolutely fine. For the fabled 'average user', they have a pretty stable core of applications available on install that'll let you do most of what you want.

Of course, i spent the next day trying to work out why the repository version of azureus was fucked, but m'eh.

I suppose the system at the moment is at a kind of halfway point where it needs a relatively tech-literate person to keep an eye on it in case a (still quite common) problem pops up, but for normal usage, it will get along fine with most people.

Of course, this could be true of any distro - my experience is kinda limited.

I've persuaded two of my friends who are getting bored of windows running slow and taking up all their space to install linux. Gonna spend a nice day tomorrow installing it all. It'll be fun to see how much sense it makes to a stranger to the thing.

I'm slowing moving towards the idea of running ubuntu, or some form of linux on my macbook. It might be a slight step down in terms of flash gui and simple made-to-run-with-this-hardware-ness, but i'm starting to learn more about free/open software at the same time as apple become more and more restrictive with their products. We'll see.

A question - In what way are unix and linux different? I realise the way they do things is a bit different - different terminal commands for stuff, etc. But what actually goes on in them that makes them different? Why is linux used more for desktops, while unix is used more for servers? Is it worthwhile trying use unix on a home comp?
 
  
Add Your Reply