What's Wrong with Unix? 1318
aaron240 asks: "When Google published the GLAT (Google Labs Aptitude Test) the Unix question was intriguing. They asked an open-ended question about what is wrong with Unix and how you might fix it. Rob Pike touched on the question in his Slashdot interview from October. What insightful answers did the rest of Slashdot give when they applied to work at Google? To repeat the actual question, 'What's broken with Unix? How would you fix it?'"
Re:you mean those guys that had their things cut o (Score:4, Informative)
Plan9 is what's right with UNIX (Score:5, Informative)
GNU Stow (Score:2, Informative)
However, I understand your problem, when it comes to manual installation. There is a project GNU Stow [gnu.org] to handle what you are talking about.
Re:Program Installation Locations (Score:3, Informative)
Package "foo", version "N" goes in "/usr/local/packages/foo-N".
The current version of "foo" has a symlink to it from "/usr/local/packages/foo".
"/usr/local/bin" contains symlinks to the appropriate files in "/usr/local/packages/*/bin"
Upgrades (and downgrades) are trivial.
Unix is too powerful (Score:3, Informative)
It's a canonical example of something that tries to be everything to everybody, but ends up being too hard for anyone to use.
Whats broken with unix? (Score:3, Informative)
But there are lots of subsystems that aren't exactly perfect.
Examples that come to mind:
*File permissions only go to user/group/others rather than individuals, and poor record locking on network shares. Lack of automounting as an intrinsic feature of the operating system.
*Windowing subsystems that network, but cant handle 3d networked graphics effectively, or support the more advanced hardware features of graphics chips locally particulaly well.
*Software packaging systems that develop conflicts. (Probably more of a linux problem, actually)
- I am aware that all of these have workarounds or are being worked on -
The kernel of most unix's (and, for that matter linux) are fairly well tuned to a variety of things, although they are subject to a number of internal revisions to try and do better multi tasking & multiple processor scaling, for example.
Where these systems will probably fail the most is when the underlying hardware changes alot - for example handling larger memory spaces and file systems, or perhaps even moving to whole new processes (eg., code morphing cpu's such as transmeta's, asynchronous cpu's). These designs are quite radically different and we have developed down a specific cpu/memory/harddrive model so far that its quite difficult to look at major changes, as they aren't as easily supported by the operating systems.
Just my 2c, and from a fairly casual observer status - it would be interesting to hear what the main developers think on all of this.
Michael
Re:Several frustrating points (Score:2, Informative)
Re:Program Installation Locations (Score:5, Informative)
Re:User Friendly (Score:4, Informative)
Re:mmap (Score:3, Informative)
I don't think the solution is to start removing functionality. The solution is to use that functionality in the correct way. A program can receive a signal at any time. This is a cold, hard fact. If your program uses operating system features that could lead to exception conditions and signals, you should handle those signals appropriately.
Re:Program Installation Locations (Score:3, Informative)
Re:In a word... (Score:4, Informative)
- PS you can very easily convert to PDF - none for PCL!
- there tons of tools which enables you "4 pages in 1", accounting quotas etc. etc. - none for PCL!
- try to display PCL file
- WHICH PCL? PCL5? PCL3?...
There is simply NO reason to give up - tell me one single argument (except VERY slight speed-up) which will balance the loosen flexibility and necessary to rewrite all existing tools (CUPS, print drivers etc.)
Re:In a word... (Score:5, Informative)
>
>PCL is available on every major printer on the market today - it IS the standard. PostScript is a has-been. Dump it today.
Huh? I think you've got that backwards.
PCL requires that most of the "brains" exist on the "computer" side of the "computer/printer" connection. A PCL printer needs less "brains" than a Postscript printer because all the processing is done on the "computer" side of the connection.
Not to put too fine a point on it, but a PCL printer is to a Postscript printer what a Winmodem is to a hardware modem.
For printers, the PCL tradeoff made a lot of sense sense when embedded CPUs were (extremely) limited in computational power compared with desktop CPUs. Rather than have your $1500 486-33 sitting idle as it dumps a pile of Postscript code to another $1000 68020 in the printer, I'll use my $1500 desktop CPU to turn my document into PCL that can be parsed by the $1.99 Z80 or whatever's in my $100 PCL printer.
Now that your $25 disposable cell phone has a 200 MHz core, that tradeoff is no longer a requirement. Embedded systems smart enough to interpret and run Postscript code are no more (and no less) expensive than those capable only of PCL.
Methinks you've got the PCL/Postscript design tradeoff backwards.
Re:needs some VMS stuff (Score:5, Informative)
Re:needs some VMS stuff (Score:3, Informative)
If I have write permission to the directory, then I can actually call "unlink" (UNIX system call which will delete a file).
Lacking write permission to the directory, I can't delete a file (or create a file). If I have permission to write to the file, I can destroy it's contents, but I can't stop the file from existing.
However, I believe in most modern UNIX filesystems you can set the "APPEND ONLY" attribute, which is handy for some things (log files), I want you to be able to write a the end of the file, but the prior contents must always exist.
Kirby
Re:Program Installation Locations (Score:2, Informative)
Actually, there is a difference between
Re:Mac OS X... (Score:3, Informative)
You would create the following directory structure:
foo.app
--Contents
----MacOs
-----
Inside the foo.app folder, you can put all of the libraries, data files, help system, etc that your program needs.
When you are browsing through in the Finder, the
One of the neatest things is that you can do this with a Java program, and the OS will launch it properly. I wish it were easier to launch jars in Windows like this.
Like elektra? (Score:4, Informative)
Ideally all confi files would follow the same format and syntax (god no please don't say XML).
Ideally there would be a uniform way for programs to retrieve configuration information from a centrallized location.
Ideally local users and machines would be able to merge their prefs and config with the master to override certain prefs.
Ideally the hierarcy of administrators would be able to prevent entitities under them from overriding certain configuration options.
Ideally all of that could be done with plain text files which are automatically checked into a version control repository so you can roll back any change in a jiffy.
There was a project on sourceforge that adresses some of the points you raise. Originally it was called "Linux-registry" I believe, now it's called Elektra [sourceforge.net].
I don't know how far they've come or anything about the project, but it looks like something that You'd want to have a look at.
Re:Program Installation Locations (Score:5, Informative)
How is this not better than the current Unix way of doing things?
Re:Better Compiler (Score:2, Informative)
Re:Program Installation Locations (Score:3, Informative)
Re:Program Installation Locations (Score:1, Informative)
In this way, average users aren't even aware that an application is a folder and consists of several files. All they see is one object, which to them is *the* application, which they can put wherever they want, and double-click from wherever they want, and it will still run.
Of course, if you wanna mess with all the little files inside an application, you can always use the terminal.
Re:Here's a start: (Score:1, Informative)
Re:Like elektra? (Score:4, Informative)
Re:Program Installation Locations (Score:5, Informative)
Re:Several frustrating points (Score:1, Informative)
Re:Several frustrating points (Score:5, Informative)
even with a package manager, you can't even determine how big a given package is! (if you know how to with Portage, I'd like to know)
equery size package
equery is part of gentoolkit
Re:OS X (Score:1, Informative)
The reason for defaulting to case insensitive HFS+ is because case-insensitive but case-preserving is fundamentally more friendly to non-geeks. To somebody who doesn't know in their bones that capital letters are different ASCII codes from lowercase, there is no obvious reason why the computer would think that files named 'joe's taxes' and 'Joe's Taxes' are different entities.
If you desire, you can create UFS file systems which (like UFS anywhere) are case-sensitive. In 10.3, it is also an option to create case-sensitive HFS+ filesystems. (You must use command line tools to do so in the client version of 10.3; it's only exposed in the GUI of the server version.)
Re:Several frustrating points (Score:3, Informative)
Deleting a file in Unix simply means removing the file's entry from it's containing directory. This is why deleting a file in Unix requires write permission on the parent directory, and has nothing to do with the permissions on the file itself.
Re:Several frustrating points (Score:5, Informative)
> of Linux in the business community.
This is not at all insightful. It is uninformed at best. Posix ACLs exist on ext2/3,xfs,reiser,jfs. These ACLs are also completely supported by Samba (and have been for many years).
-Mark
Re:configuration (Score:3, Informative)
-Mark
Re:Several frustrating points (Score:2, Informative)
Unix needs something [infoworld.com] like MSH [infoworld.com], I think.
Of course, there are plenty of good scripting [python.org] of languages [ruby-lang.org] for Unix. The question is whether we need some higher-level glue between scriptable components, and I think we do.
Re:Program Installation Locations (Score:3, Informative)
No, it doesn't. The installer framework does record the installed files in package 'receipt' files, but there's no standard way to uninstall a package.
Re:A good set of standards. (Score:1, Informative)
Okay, I want to:
1) embed different spreadsheets each with cascading spreadsheets into multiple cells of a main spreadsheet -- easy with MS Office, can't do it in Linsux OpenOffice.
2) embed video clips into a slide presentation -- easy with MS Power Point, can't be done with any Linsux software
3) print a complex document to a $40 printer -- easy for Windows, not for Linsux
4) play the hottest videogames -- easy in Windows, can't be done for Linsux
5) off load an arbitrary digital camera's photos to a computer by USB -- easy for nearly any camera and current Windows system, impossible for most Linsux systems
6) add arbitrary PCI hardware, usb hardware, serial/joystick port hardware without worrying about drivers -- mostly automatic for Windows, a horrendous task for Linsux.
7) add a local PC via cross-over patch cable to a laptop connected by WiFi to a NAT enabled wireless router -- easy with Windows network wizard, a much more complicated, table editing, config file changing task with Linsux.
Those are just a few of the tasks this week off the top of my head. People that routinely use both Windows and Linux know what's easy and not so easy to do in each OS, so don't come off so fucking high and mighty because you'll just look incredibly stupid.
My videos, DVDs, audio stuff all just comes up running from the main menu which accesses the file system for content. I have yet to see a windose (sic) desktop with anywhere close to the usability I've built into my window manager.
Dufus, Windows has My Pictures and My Music directories already created out of the box for each new user. Comes standard with Windows Media Player that plays all DVD's and most audio formats by clicking a file name or automatically by simply inserting a CD/DVD. No "setting up" required.
Re:Here's a start: (Score:3, Informative)
Sure. In fact here's two.
Generic Windows Hello World program (in C) [microsoft.com]
Alternatively, how about this one... Hello World for Win32 [microsoft.com]
There you go.
Please take this person's notion that MSDN is world's above what Linux or some other UNIX has with a grain of salt. Also, docs.sun.com and sunsolve.sun.com have always worked adequately for me.
While you're at it, you might also want to question the person I'm responding to, who apparently can't search their way out of a paper bag.
Re:IMHO, none of that matters to the typical end u (Score:3, Informative)
I've installed both on several distributions. I have to tell the Flash installer where Mozilla and it handles the rest. For Java, I have to create a symbolic link to it in my Mozilla plugins directory. They both work fine, except that the sound and video get out of sync in Flash.
Small developers have to either open source or pay fees they cannot afford to obtain a "widget set", something that any other OS supplies for free, and defines a standard for.
Except for Qt, most do not require you to pay a fee or open source your app.
Linux has a pretty poor cache and swap system, combined with zero user level control over cache and swap. As a result, over time, the OS runs slower, and s l o w e r and s... l.... o..... w...... r....... until you restart,
I saw this mentioned in the Red Hat bugzilla, affecting RH9 and some RHEL3 users. But they say it was fixed mostly in 2.4.24 and completely in 2.6.
The GUI, in the user sense, is an afterthought. You have to go to the command line to configure and/or adjust and/or install many things.
Yeah, but I have to use the Windows command line for a lot of things, or dig around in the registry. People who can't on Windows get help from those who can. The actual amount of command line work necessary in Linux varies between distributions. I can do a lot more fron the Linux command line than from the Windows command line, so I'm more apt to use it.
So mostly, people don't run Linux.
But I'll always run it. Ubuntu is starting to look good. I'm running the unstable hoary hedgehog branch scheduled for release in about 4-5 months. Lots of nice things appear to be on the way.
Re:Several frustrating points (Score:4, Informative)
I dunno, maybe you're just trolling (and a number of replies that follow would qualify you as a good troll), but I'd say that installing FreeBSD is not any more difficult than, say, Slackware or Debian. It is more challenging than your Mandrake or RH install, I think (have not had a chance in the last 3-4 years to try either).
That said, with enough preparation and a chapter from the Handbook [freebsd.org] printed out and within a reach installing stock FreeBSD should not be a problem at all.
The question you should, however, ask yourself is Why do I want to try FreeBSD? If it is just because you've heard it's cool -- you may be much better off trying a http://www.freesbie.org/ [freesbie.org] instead. It's a live FreeBSD ssytem, sort of like Knoppix.
If you want to give FreeBSD a spin because you want to understand UNIX-land better or have needs for the stability of the platform, then rough starts should not be anything to discourage you.
In either case -- all the best and have fun!
Re:OS X (Score:2, Informative)
Unintuitively, nonetheless.
Re:That's not just unix. :P (Score:2, Informative)
No shit! I hate them mother fuckers. Maybe I would RTFM if the programs I need help with HAD A FUCKING MAN PAGE! Idiots...
Try out channel #mepis for MEPIS Linux; I hang out in there and they are very nice, and even help out for other distros.
Re:Several frustrating points (Score:2, Informative)
Wrong. Permissions and other file metadata relate to the inode not the directory entry.
I suppose the reason noone else has bothered to point this out already is that it is trivial. But perhaps it'd better be stated explicitly.
-Lasse
Re:UNIX new year's resolutions (Score:3, Informative)
Privileged port is pretty much as you say, a joke. I am particularly amused by IRC servers dependence on ident responses as a way to validate a user connecting
The info format was meant to supercede man pages. There is a lot more flexibility, but I am torn. In day to day use I find a preference for man pages, simple, easy to search. However, man pages don't scale that well (man bash for example), and sometimes the typical string search for what you want will take forever to iterate through. Arguably more widespread html documentation coupled with text web browsers like links would give more flexible options in a more comfortable way.
What exactly is your complaint about
As far as all the directories and where things go, there are pretty established standards, the problem being, of course, that not all groups know them well or bother to follow them, so they kind of get trashed. I personally think mostly self contained application/library suite directories are nice (ROX file manager supports it). I.e. the entirety of GTK would be
Most everything else I can't disagree with. Particularly the notion of detachable X11 sessions ala screen for terminals.
Re:Several frustrating points (Score:3, Informative)
Without a package manager, it's practically impossible to remove a program; even with a package manager, you can't even determine how big a given package is! (if you know how to with Portage, I'd like to know).
If the program in question was originally installed with a package manager, why would you try to remove it without using the package manager? If you are installing from source, on the other hand, I think what you are looking for is GNU stow [gnu.org]. With stow, you install a program (say it's called foo) like this:
All that the "stow foo" step does is create symlinks from the normal dirs in /usr/local into the foo subdirectory, so you don't need to fuss with $PATH, $LD_LIBRARY_PATH, etc. to run the program. Upgrading or uninstalling foo later becomes trivial because all you have to do is run "stow -D" on the subdirectory (to remove the symlinks), recursively delete it, and (if desired) repeat the above set of commands to install the new version of foo. And to find the installed size: du -sk /usr/local/stow/foo-0.0.1
A better filesystem layout (perhaps the way MacOSX, GoboLinux or RoX does it) would make package managers obsolete.
Not true: in addition to file layout (which is arguably the easiest job for a package manager to handle), they deal with dependencies, post-installation setup scripts, config file handling, etc.