LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-21-2009, 02:40 PM   #1
carlos the jackal
LQ Newbie
 
Registered: May 2007
Posts: 19

Rep: Reputation: 0
Linux principles - several questions in this!


Bonjour boys and girls
I've been a member for a while, and tho I installed slack and played with a 'little bit', I went back to windows, and seldomly did I look up LQ. boo to me.
In reality I should just pull my finger out and get on with it.
So after some careful deep mulling, here I am with some principled questions, almost certainly the same questions that everyone else has been asking ...

1 Linux is the Kernel - the common bit between every distro. Would it be fair to say, then, that each and every distribution is actually a completely separate operating system in its own right, that theres no such thing as THE LINUX OPERATING SYSTEM, rather there are many operating systems similar to Unix which use the Linux kernel (although in reality they are quite similar to each other )?

2 Is it fair to say that each of the 3 BSD's are totally different to each other, and different to each of the linux distros? If so, why list it in LQ?

3 The Shell. Bash is the default. Is it true that everything you type at the prompt is processed by the shell? Ie when you are typeing, its jsut the shell reading stand input?

4 Is it mandatory to have a shell? What would the system be like if you didnt have a shell? What could you NOT do if you didnt have the shell

5 Ive read good things about knoppix, how small and powerful it is. How come its so small? does it still have the whole of the kernel?

6 Slack is big, so there must be some things slack can do that knoppix cannot. I wonder what they are? Similary, knoppix can do quite alot - is it fair to say that slack can do everything that knoppix can do?

ok thats enough to go on for now. I will have more questions eventually.
Thank you guys.
 
Old 07-21-2009, 02:59 PM   #2
pljvaldez
LQ Guru
 
Registered: Dec 2005
Location: Somewhere on the String
Distribution: Debian Wheezy (x86)
Posts: 6,094

Rep: Reputation: 271Reputation: 271Reputation: 271
Quote:
Originally Posted by carlos the jackal View Post
1 Linux is the Kernel - the common bit between every distro. Would it be fair to say, then, that each and every distribution is actually a completely separate operating system in its own right, that theres no such thing as THE LINUX OPERATING SYSTEM, rather there are many operating systems similar to Unix which use the Linux kernel (although in reality they are quite similar to each other )?
That's fair to say. Though many distros try to meet things like the Linux Standards Base so that things are at least stored in a similar area. Many people argue this is a major reason why linux will never be the dominant OS, because it is too fragmented. Others see it as a positive that there is so much choice.
Quote:
2 Is it fair to say that each of the 3 BSD's are totally different to each other, and different to each of the linux distros? If so, why list it in LQ?
Yes again. Because we're a helpful community and there is enough overlap that certain things work on all *nix like operating systems.
Quote:
3 The Shell. Bash is the default. Is it true that everything you type at the prompt is processed by the shell? Ie when you are typeing, its jsut the shell reading stand input?
I would assume so, but I don't really know. I do know there are some special combinations that may or may not bypass the shell and access the kernel directly.
Quote:
4 Is it mandatory to have a shell? What would the system be like if you didnt have a shell? What could you NOT do if you didnt have the shell
No idea.
Quote:
5 Ive read good things about knoppix, how small and powerful it is. How come its so small? does it still have the whole of the kernel?
Knoppix is not really all that small. Something like TinyMe or Damn Small Linux is small. Knoppix was novel during it's creation because it used a clever compression scheme to fit a large (like 2GB) system onto a regular sized CD without creating an enormous performance hit.
Quote:
6 Slack is big, so there must be some things slack can do that knoppix cannot. I wonder what they are? Similary, knoppix can do quite alot - is it fair to say that slack can do everything that knoppix can do?
Size of distro basically depends on what programs you install. Slack can be really lean. Slack can also be huge. Knoppix has pre-selected what packages you get. Debian has something like 32 CD's worth of programs you could install. Would you do that? Probably not. I've had Debian down to 600MB before after install. Of course, no gui, openoffice, etc.
 
Old 07-21-2009, 03:01 PM   #3
johnsfine
LQ Guru
 
Registered: Dec 2007
Distribution: Centos
Posts: 5,286

Rep: Reputation: 1190Reputation: 1190Reputation: 1190Reputation: 1190Reputation: 1190Reputation: 1190Reputation: 1190Reputation: 1190Reputation: 1190
Quote:
Originally Posted by carlos the jackal View Post
1 Linux is the Kernel - the common bit between every distro.
Lots of other GNU software and other open source software is in common across many, most, or maybe all Linux distributions.

I guess it wouldn't be a Linux distribution without a Linux kernel, but many other components are part of what the user sees as Linux.

Quote:
Would it be fair to say, then, that each and every distribution is actually a completely separate operating system in its own right
That's meaningless distinction. There is no point to trying to decide what is or isn't a separate OS.

Quote:
4 Is it mandatory to have a shell? What would the system be like if you didnt have a shell? What could you NOT do if you didnt have the shell
Quite a lot of scripts run behind the scenes use the shell. That includes startup scripts run before you ever see a GUI as well as scripts that many GUI programs invoke in order to do the actual work.

So with most distributions, if you didn't have a shell you wouldn't have anything (your system wouldn't even start).

You could put together an embedded system with a Linux kernel and no shell. You can boot a typical installed Linux system into some selected application program run directly under the kernel without a shell. But to most users neither of those would really be "Linux".
 
Old 07-21-2009, 03:05 PM   #4
tredegar
LQ 5k Club
 
Registered: May 2003
Location: London, UK
Distribution: Debian "Jessie"
Posts: 6,087

Rep: Reputation: 407Reputation: 407Reputation: 407Reputation: 407Reputation: 407
Oh No!!
I sense .... ... .. . flamewars ("The kernel is linux", "No, linux is the kernel", "GNU's not unix", "Slack", "Ubuntu's not "linux"", "linux from Scratch", "GPG" ... )
Quote:
In reality I should just pull my finger out and get on with it.
Yes. You got there in one

Welcome to LQ after all this time ( You registered in 2007, what's been keeping you away? )
 
Old 07-21-2009, 03:29 PM   #5
onebuck
Moderator
 
Registered: Jan 2005
Location: Midwest USA, Central Illinois
Distribution: Slackware®
Posts: 12,900
Blog Entries: 27

Rep: Reputation: 2186Reputation: 2186Reputation: 2186Reputation: 2186Reputation: 2186Reputation: 2186Reputation: 2186Reputation: 2186Reputation: 2186Reputation: 2186Reputation: 2186
Hi,

Welcome to LQ!

Read the next two links;
 
Old 07-22-2009, 08:53 AM   #6
carlos the jackal
LQ Newbie
 
Registered: May 2007
Posts: 19

Original Poster
Rep: Reputation: 0
ok muchos gracias to all you guys, very helpful.

I did register in 2007, yes. Whats been keeping me away? boring stuff. Laziness mainly (watching rubbish tv), lots and lots of World of Warcaft, girlfriend, some running, piano lesson, open university, house issues, etc ... daft list goes on.

OK, pianos over, open university doing nothing for about 6 months, world of warcraft getting dull - Im going to pull my finger out on Saturday. Time to install Slack again. I'll read those links/manuals too (thanks for those) , then I will no doubt have more questions for you all

My task ahead remains an exciting one, an adventure of which the treasures will be great. Thank you, gracious allies.
 
Old 07-22-2009, 10:13 AM   #7
rich_c
Member
 
Registered: Apr 2008
Location: UK
Distribution: openSUSE, Fedora
Posts: 385
Blog Entries: 74

Rep: Reputation: 81
I'm guessing from what you've posted that you're going for Slack because you want to learn how to do stuff rather than having an all-the-bells-and-whistles system straight away?

If I'm right, that's very refreshing in these times when people tend to want it all now. I wish you well on your journey!

From my profile info, you might notice that I tend to go for distros that have a reputation for just working!
 
Old 07-24-2009, 07:46 AM   #8
carlos the jackal
LQ Newbie
 
Registered: May 2007
Posts: 19

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by rich_c View Post
I'm guessing from what you've posted that you're going for Slack because you want to learn how to do stuff rather than having an all-the-bells-and-whistles system straight away?

If I'm right, that's very refreshing in these times when people tend to want it all now. I wish you well on your journey!

From my profile info, you might notice that I tend to go for distros that have a reputation for just working!
Well kind of - when I saw that Linux distros can have lots of different window managers and desktops etc , I was impressed. I remember trying a few the last time - blackbox, fluxbox, windowmaker ... great fun! Just curious to see how it all hangs together etc!
 
Old 07-24-2009, 08:21 AM   #9
Hangdog42
LQ Veteran
 
Registered: Feb 2003
Location: Maryland
Distribution: Slackware
Posts: 7,803
Blog Entries: 1

Rep: Reputation: 416Reputation: 416Reputation: 416Reputation: 416Reputation: 416
Quote:
Originally Posted by carlos the jackal
4 Is it mandatory to have a shell? What would the system be like if you didnt have a shell? What could you NOT do if you didnt have the shell
Since no one has picked this up, I'll give it a go.

The answer is no, it is NOT mandatory to have a shell. In fact, Slackware comes with several default account that don't have a shell (have a look at /etc/passwd and you'll see several accounts with /bin/false as their shell). These accounts are mainly used for running servers. Take the apache account for example, which is used to run the Apache server. When Apache is first started, it is being run as root, but after it gets going, root switches the processes to run under the apache account. This is mainly for security as the apache user can't really do much.

Have a look at the su command which can be used to run specific processes as a user that doesn't have a shell.
 
Old 07-29-2009, 07:02 PM   #10
carlos the jackal
LQ Newbie
 
Registered: May 2007
Posts: 19

Original Poster
Rep: Reputation: 0
ok ive got my first problem with installing Slack - and it is the very first thing.
See this link for the problem ...

http://www.basicconfig.com/slackware...size=_original

pressing enter here gives the error ..
"not enough memory to load specified kernel." I suspect this maybe because my harddrive is sata, so i think im supposed to choose sata version of kernel, but I cant see the list of kernels.
It says press f2 for a list of kernels, but when i press f2, no list appears.

And there doesnt seem to be any documentation in Slack's site.

Also, i do not belive that this is the right place for this problem, so I will go to slack threads now.

Going back to original question - what does the shell actually do? Anyone know what Linux would be like without a shell? Cheers.

Last edited by carlos the jackal; 07-29-2009 at 07:16 PM.
 
Old 07-30-2009, 02:27 AM   #11
catkin
LQ 5k Club
 
Registered: Dec 2008
Location: Tamil Nadu, India
Distribution: Debian
Posts: 8,576
Blog Entries: 31

Rep: Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195
Hello carlos
Quote:
Originally Posted by carlos the jackal View Post
Going back to original question - what does the shell actually do? Anyone know what Linux would be like without a shell? Cheers.
A shell (for there are many) processes commands typed in by the user. Before GUIs that was the only way for a user to interact with the operating system. As it says on Wikipedia, The name 'shell' originates from shells being an outer layer of interface between the user and the innards of the operating system (the kernel).

Because UNIX was written by smart computing pioneers for smart computing pioneers it was a powerful beast right from the beginning and got a lot smarter in the next 40 years.

In fact it's so smart that it has a programming language -- shellscript -- that the user can use to build commands for execution. Every line typed in is processed as if it were a shellscript statement. At simplest the "statement" is just the name of a command to run like
Code:
date
or the name of a command to run plus some values for it to use
Code:
ls -l some.pdf
When the shell was invented there were no screens. Users interacted with the computer using "teletypes" a kind of combined typewriter and printer. You typed your command, it printed on paper and the computer's response was printed after that. Those things were slow and there was no copy-and-paste. Everything had to be typed so UNIX commands are very short -- it was easier to remember short commands than to continuously type in long ones. The legacy is still with us; "ls" stands for "list" and lists files; its "-l" option asks for "long" (detailed) format.

File names would have taken a lot of typing so the shell has "file name expansion", for example "*" is expanded to the names of all the files in the current directory. Hence
Code:
ls -l *
lets the user list details of all the files in the current directory.

Another shell feature to reduce typing was being able to send the output of one command to another through a "pipe" denoted by the "|" character (looks like a pipe stood on end?) so
Code:
ls -l * | wc -l
gives the number of files the current directory. The "ls" lists the files, one per line and the shell pipes this list to wc (word count) that normally lists the number of characters, words and lines but with the -l option gives only the number of lines.

This shell feature led to the UNIX philosophy of creating commands that do one simple job and do it well, designed for piping together to do complex jobs in a very flexible way.

And so on ... the shell is a rich programming language, with conditionals, loops, functions, tracing etc. Shellscript does not have to be entered at the command prompt; it can also be stored in files which can be passed to the shell for execution. This is a neat way to automate routine tasks.

With the UNIX developers using such a great tool in their day to day work it was natural that they should use it to automate systems administration, including automating the boot process. As a result shellscript is so embedded in *n*x that it is difficult (not impossible!) to imagine a system without it.

It is testimony to the genius of UNIX' developers that they designed a shell so elegant, flexible and powerful that it is still in widespread use 40 years after they began. Many *n*x GUIs actually generate shellscripts to do their work!

Best

Charles
 
Old 07-30-2009, 03:31 AM   #12
Nylex
LQ Addict
 
Registered: Jul 2003
Location: London, UK
Distribution: Slackware
Posts: 7,464

Rep: Reputation: Disabled
Quote:
Originally Posted by carlos the jackal View Post
ok ive got my first problem with installing Slack - and it is the very first thing.
See this link for the problem ...

http://www.basicconfig.com/slackware...size=_original

pressing enter here gives the error ..
"not enough memory to load specified kernel." I suspect this maybe because my harddrive is sata, so i think im supposed to choose sata version of kernel, but I cant see the list of kernels.
It says press f2 for a list of kernels, but when i press f2, no list appears.

And there doesnt seem to be any documentation in Slack's site.

Also, i do not belive that this is the right place for this problem, so I will go to slack threads now.
I suggest that you make a new thread for this problem, since it's quite unrelated to the current thread.
 
Old 07-30-2009, 03:40 AM   #13
carlos the jackal
LQ Newbie
 
Registered: May 2007
Posts: 19

Original Poster
Rep: Reputation: 0
ok i think i sort of understand now. thanks all. I'll plug on.
 
Old 07-30-2009, 06:18 AM   #14
salasi
Senior Member
 
Registered: Jul 2007
Location: Directly above centre of the earth, UK
Distribution: SuSE, plus some hopping
Posts: 4,064

Rep: Reputation: 894Reputation: 894Reputation: 894Reputation: 894Reputation: 894Reputation: 894Reputation: 894
Quote:
Originally Posted by carlos the jackal View Post

4 Is it mandatory to have a shell? What would the system be like if you didnt have a shell? What could you NOT do if you didnt have the shell
No. in a certain category of embedded devices, you could say that it is usual not to have a shell, at least not available to a user.

The system would be very like a Linux system that didn't have a shell

What this means to a user rather depends on what user interface you get instead. You'd hope that if the thing was a video recorder, you'd design an interface that was, at least conceptually, like a video recorder interface. You could design an interface that was like, say, a fridge or a toaster or a motor car, but surely that would make the thing hard to sell, wouldn't it?

Of course, the question what the system would be like is so lacking in definition as to be able to accept all sorts of answers; I chose to answer what the system would be like to a user, but you could choose to answer how the memory would be used, how multi-tasking looks, how scheduling looks...but mostly the answer is its like linux, but with no shell.

Quote:
5 Ive read good things about knoppix, how small and powerful it is. How come its so small? does it still have the whole of the kernel?
Well, its not really relevant to the rest of the thread, but knoppix is quite a nice system, particularly if you want what it does well (is a live CD/DVD).

It is only really small if there isn't much installed. OTOH, it may have, in the most recent versions, have a small memory footprint, which is a different kind of small, because it uses a relatively small GUI. The memory footprint would then be similar to other distros using this compact GUI, so in comparing with something that has the options to fit either a small or a large footprint GUI doesn't seem very meaningful, because the first part of the answer is always going to be, 'Are you comparing with a similar size of GUI?'.

If not, my prediction is that you will find the surprising information that large GUIs are larger than small ones. And vice versa.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: The open source principles of participation LXer Syndicated Linux News 0 09-13-2008 05:50 AM
LXer: Microsoft's Interoperability Principles and IE8 LXer Syndicated Linux News 0 03-04-2008 06:30 PM
Biometrics principles green_dood Linux - Newbie 1 01-10-2008 09:11 AM
LXer: Transparency, principles, and the Microsoft way... LXer Syndicated Linux News 0 07-30-2006 08:54 PM
Design Principles waikit0513 Linux - General 4 09-02-2005 05:24 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:17 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration