Welcome, Guest. Please Login
 
  HomeHelpSearchLogin FAQ Radified Ghost.Classic Ghost.New Bootable CD Blog  
 
Pages: 1 2 3 
Send Topic Print
Continued: Linux and Shell Scripting (Read 19532 times)
Rad.in.UbuntuVM
Radmeister
**
Offline


Rad in Ubuntu 9.04 Jaunty
Virtual Machine

Posts: 92


Back to top
Re: Continued: Linux and Shell Scripting
Reply #15 - Jul 7th, 2009 at 1:20am
 
MrMagoo wrote on Jul 7th, 2009 at 12:17am:
Xorg provides the graphical environment for Linux. 

is xorg different from xwindows? or are they talking about the same thing?

MrMagoo wrote on Jul 7th, 2009 at 12:08am:
To me, Linux's greatest strength is that it is free (as in free speech.)

this requires a knowledge of programming, yes? what language is/was used to prgm linux? what do you use to compile your modded versions?
 
WWW  
IP Logged
 

MrMagoo
Übermensch
*****
Offline


Resident Linux Guru

Posts: 1026
Phoenix, AZ (USA)


Back to top
Re: Continued: Linux and Shell Scripting
Reply #16 - Jul 7th, 2009 at 4:23pm
 
Rad.in.UbuntuVM wrote on Jul 7th, 2009 at 1:20am:
is xorg different from xwindows? or are they talking about the same thing?

X.org is the organization that makes XWindows.

Rad.in.UbuntuVM wrote on Jul 7th, 2009 at 1:20am:
this requires a knowledge of programming, yes?

No, usually it doesn't.  That's what was getting at mentioning the world-wide user-base.  I've found that someone has usually already written something that does what I want to do.  If you know how to install the program you need and configure the system to use it, you are set.

Rad.in.UbuntuVM wrote on Jul 7th, 2009 at 1:20am:
what language is/was used to prgm linux?

Mostly C.

Rad.in.UbuntuVM wrote on Jul 7th, 2009 at 1:20am:
what do you use to compile your modded versions? 

The gcc compiler is sort of the standard compiler for Linux.  It is (of course) free (as in speech and beer.)
 
WWW  
IP Logged
 
MrMagoo
Übermensch
*****
Offline


Resident Linux Guru

Posts: 1026
Phoenix, AZ (USA)


Back to top
Re: Continued: Linux and Shell Scripting
Reply #17 - Jul 7th, 2009 at 4:54pm
 
Rad.in.UbuntuVM wrote on Jul 6th, 2009 at 11:37pm:
i am not clear on the concept of a mount point. can you explain how that works?

So Linux doesn't address it's drives with A:, B:, C:, etc, which if you think about it, is kind of abitrary anyway.  Instead, Linux uses mount points.  A mount point is little more than an empty folder that the contents of a disk sits in. 

Say you have one drive with 3 partitions.  Partition 1 is your root partition ("/").  The contents of that partition get mounted at the root "/" mount point.  That partition is going to contain a bunch of files and folders.  How, say paritition 2 has your home directories.  Partition 1 will have an empty folder named /home.  Partition 2 will have all your home directories (rad, magoo, user3, user4, etc.)  You mount partition 2 in the empty folder /home.  Now, /home is no longer empty, and you can access the contents of partition 2 by browsing /home/rad, /home/magoo, /home/user3, etc.

Now, say user4 has a TON of data, so it doesn't fit on the same partition as all your other home folders.  So, user4's data is on partition3.  You can mount partition3 onto /home/user4.  Now, that data is accessible there, right where it should be.

Windows will also let you mount partitions into empty folders, achieving the exact same effect, but I've never seen it done by anyone but me in practice.
 
WWW  
IP Logged
 
Spanky
Radmeister
**
Offline


Rad's non-Admin Test profile
in Seamonkey

Posts: 73
Same as Rad


Back to top
Re: Continued: Linux and Shell Scripting
Reply #18 - Jul 7th, 2009 at 10:05pm
 
MrMagoo wrote on Jul 7th, 2009 at 4:23pm:
Mostly C.

so if you wanna tweak the linux source code, you would do that in/with C?

have you ever tweaked the kernel?
 
WWW  
IP Logged
 
MrMagoo
Übermensch
*****
Offline


Resident Linux Guru

Posts: 1026
Phoenix, AZ (USA)


Back to top
Re: Continued: Linux and Shell Scripting
Reply #19 - Jul 7th, 2009 at 11:49pm
 
Spanky wrote on Jul 7th, 2009 at 10:05pm:
so if you wanna tweak the linux source code, you would do that in/with C?

Yes.  Most of the OS is written in C. 

Spanky wrote on Jul 7th, 2009 at 10:05pm:
have you ever tweaked the kernel?

No, I've never changed the source code. 

I have compiled a custom kernel.  Compiling your own kernel allows you to remove modules you don't need and compile in custom stuff.  You can make it faster, or more secure, or tweak a lot of other things to fit your needs.  It doesn't require editing C source code, tho.  You can edit text-based make files or use a menu based kernel compiler.  It does take a good understanding of what your particular situation requires from the kernel.

The only common reason for compiling a custom kernel in Linux is to harden it for security.  It is more common to need a custom kernel with the BSD flavors, which is where I learned it.
 
WWW  
IP Logged
 
Rad.in.UbuntuVM
Radmeister
**
Offline


Rad in Ubuntu 9.04 Jaunty
Virtual Machine

Posts: 92


Back to top
Re: Continued: Linux and Shell Scripting
Reply #20 - Jul 12th, 2009 at 1:11am
 
MrMagoo wrote on Jul 7th, 2009 at 11:49pm:
Compiling your own kernel allows you to remove modules you don't need and compile in custom stuff. It doesn't require editing C source code, tho. 

Interesting .. especially that you don't have to edit any source code.

One thing I seem to be having trouble grasping is when you do and don't add an initial fwd slash when using paths to various files and folders.

I understand the concept of relative (to the current directory) and absolute paths. Most of the time, it seems an initial fwd slash is NOT used .. e.g » business/reports/july/sales.txt

but then other times i see them using the fwd slash, such as » /tmp/sales.txt

Can you provide any insight on when the initial fwd slash is (and isn't) used??

or maybe when you WOULD use the initial fwd slash, cuz it seems like it;s normally not used.
 
WWW  
IP Logged
 

Rad.in.UbuntuVM
Radmeister
**
Offline


Rad in Ubuntu 9.04 Jaunty
Virtual Machine

Posts: 92


Back to top
Re: Continued: Linux and Shell Scripting
Reply #21 - Jul 12th, 2009 at 12:46pm
 
after further research, it seems the initial fwd slash is only used when using an absolute path, and that means that the initial fwd slash refers to the root ("slash") directory.

yes?

this would make sense.

so you could actually be IN the root / directory, but would still not use the initial fwd slash when typing a path name to a file buried several directories deep, if that path name was relative. and to make that path name absolute, you would simply add an initial fwd slash, assuming we're talking about being in the root / directory.
 
WWW  
IP Logged
 
MrMagoo
Übermensch
*****
Offline


Resident Linux Guru

Posts: 1026
Phoenix, AZ (USA)


Back to top
Re: Continued: Linux and Shell Scripting
Reply #22 - Jul 12th, 2009 at 6:35pm
 
Rad.in.UbuntuVM wrote on Jul 12th, 2009 at 12:46pm:
after further research, it seems the initial fwd slash is only used when using an absolute path, and that means that the initial fwd slash refers to the root ("slash") directory.

Yes!  That's exactly what I was going to say.  The leading forward / refers to the root directory and indicates an absolute path.  An absolute path takes you to the same place no matter where you start. 

Without the leading /, a path is realtive to where you are currently at in the filesystem (know as your "working directory".)  You can find out where you are at with the command 'pwd' (which stands for "print working directory" I think.) 

So, if you are in /home/rad and you type "cd tmp", you would end up in /home/rad/tmp.  If you type "cd /tmp" you would end up in /tmp.
 
WWW  
IP Logged
 
Rad
Radministrator
*****
Offline


Sufferin' succotash

Posts: 4090
Newport Beach, California


Back to top
Re: Continued: Linux and Shell Scripting
Reply #23 - Jul 13th, 2009 at 4:24pm
 
Enjoying learning about relative vs absolute path names, cuz I've always used absolute paths when copying files, which resulted in very long strings (would have to stretch the WinSCP window across the entire screen -- 1280x800 -- to prevent the command from wrapping).

How much simpler things seem when you learn how things work.

Noticed that Apress just released a new book on CentOS .. the "definitive guide":

http://www.amazon.com/Definitive-Guide-CentOS-Peter-Membrey/dp/1430219300/

wonder if that would be worth perusing, seeing that WiredTree uses CentOS 5.

...

From the intro:

Quote:
Although CentOS has a huge number of benefits over other operating systems, we cannot
escape the fact that it’s also free. With virtual machines starting to replace traditional
hosted services, people are finding that having their own server is not only much more
flexible but also often cheaper.

But running your own server is very different from simply using a hosted service, and
this is where The Definitive Guide to CentOS comes in. It has been written to help newcomers
to the platform get up and running in production as quickly and as painlessly as
possible. Each of the chapters has a specific task-oriented goal and explains how to do the
majority of tasks that people are looking to do.

Just like CentOS itself, we hope to be able to improve and refine this definitive guide.
We would be grateful for any and all feedback with regard to the book and how it could
be improved to better suit the needs of new users. Your experiences are hard won, and we
would love to hear what you have to say. After all, The Definitive Guide to CentOS is here
to help, and who better to advise and provide feedback than the very people who have
made their first steps with it?

This book will let you hit the ground running, and the CentOS community will ensure
that you are able to keep in the race!

It is common for newcomers to Linux to set up servers using “consumer-grade” Linux
distributions such as Fedora and Ubuntu Desktop. Although these distributions make
great desktops, they’re not the ideal choice for a production server because the software
versions change on a regular basis. Enterprise Linux distributions such as CentOS maintain
specific software versions over an extended period of time, which helps to ensure
that you don’t have any nasty surprises (see the “Extended Support” section).

Examples of enterprise Linux are Red Hat Enterprise Linux, SUSE Linux Enterprise
Server, Ubuntu LTS, and CentOS. Examples of consumer Linux are Fedora, Ubuntu,
OpenSUSE, Gentoo, and Debian.

More:

Quote:
Enterprise Linux has gained an awful lot of attention recently—for very good reason. Linux
has a reputation for being updated and improved at an amazingly fast rate. Conventional
wisdom would suggest that this is a good thing. After all, it means you’re getting better
software, and that can’t be a bad thing, can it? Actually, it can, and this is one of the key
areas that enterprise Linux looks to resolve.

by the way, how is it that RedHat can CHARGE for their distro?

https://www.redhat.com/apps/store/desktop/

I thot the nature of Linux and the Linux license prevents that.

Same with Suse, no?
 
WWW  
IP Logged
 
Rad
Radministrator
*****
Offline


Sufferin' succotash

Posts: 4090
Newport Beach, California


Back to top
Re: Continued: Linux and Shell Scripting
Reply #24 - Jul 13th, 2009 at 6:00pm
 
my course says you don't use the minus sign with options for/with the tar command, yet i have and it works.

tar -xzvf

have you heard of this? .. not using - with tar options?

sounds weird.
 
WWW  
IP Logged
 
MrMagoo
Übermensch
*****
Offline


Resident Linux Guru

Posts: 1026
Phoenix, AZ (USA)


Back to top
Re: Continued: Linux and Shell Scripting
Reply #25 - Jul 13th, 2009 at 7:08pm
 
Rad wrote on Jul 13th, 2009 at 4:24pm:
wonder if that would be worth perusing, seeing that WiredTree uses CentOS 5.

Sounds like a good book right at your skill level.  I haven't read any of the "Definitive Guide to..." books, but there's a lot of them out there so they must have some success.  CentOS is a great distro to learn.

Rad wrote on Jul 13th, 2009 at 4:24pm:
by the way, how is it that RedHat can CHARGE for their distro?

I thot the nature of Linux and the Linux license prevents that.


Absolutely not.  Linux is licensed under the GPL.  You can do (almost) anything you want with GPL code, including sell it, as long as you make a copy available of any changes that you made to it.  Red Hat does make their source code available.  That's where CentOS comes from.

http://www.gnu.org/copyleft/gpl.html

Also, Red Hat is really selling tech support more than software.  If you purchase from Red Hat, they give you access to their tech support for a period of time (something like 3 years, I think.)


Rad wrote on Jul 13th, 2009 at 6:00pm:
my course says you don't use the minus sign with options for/with the tar command, yet i have and it works.


Ya, that's true for a few commands.  "ps" is another example where the - is optional ("ps aux" works the same as "ps -aux")
 
WWW  
IP Logged
 

Rad
Radministrator
*****
Offline


Sufferin' succotash

Posts: 4090
Newport Beach, California


Back to top
Re: Continued: Linux and Shell Scripting
Reply #26 - Jul 13th, 2009 at 8:57pm
 
are you certified anything? linux-wise. rhce?
 
WWW  
IP Logged
 
Rad
Radministrator
*****
Offline


Sufferin' succotash

Posts: 4090
Newport Beach, California


Back to top
Re: Continued: Linux and Shell Scripting
Reply #27 - Jul 13th, 2009 at 9:15pm
 
MrMagoo wrote on Jul 13th, 2009 at 7:08pm:
where the - is optional 

optional? well that's different from "don't use"

what's the rational behind eliminating the need for the "-" on certain commands? .. other than trying to confuse me.

MrMagoo wrote on Jul 13th, 2009 at 7:08pm:
Red Hat does make their source code available.That's where CentOS comes from.

they MUST make their source available, right? (per the GPL license) I mean, it's not a nice-guy thing they're doing, right?

If not, and they stopped, CentOS would be outta business, right?

if their source is freely available, then why are ppl PAYING for it? Why doesn't RH just sell support subscriptions? Anybody can take their source and compile it, right?

I see the logic behind selling sppt .. which is beneficial for all parties involved. But I don't get why anybody would pay hundreds of dollars for an OS they can get for free .. follow me?

Have you heard anything about RH sppt? Are they good? Okay? Suk?
 
WWW  
IP Logged
 
MrMagoo
Übermensch
*****
Offline


Resident Linux Guru

Posts: 1026
Phoenix, AZ (USA)


Back to top
Re: Continued: Linux and Shell Scripting
Reply #28 - Jul 13th, 2009 at 10:35pm
 
Rad wrote on Jul 13th, 2009 at 8:57pm:
are you certified anything? linux-wise. rhce?

I have RHCT, which is a step below RHCE.  I could probably pass the RHCE if I studied a little but I'm trying to steer my career in a different direction so I haven't put the time into it.

Rad wrote on Jul 13th, 2009 at 9:15pm:
what's the rational behind eliminating the need for the "-" on certain commands? .. other than trying to confuse me.

Well, its optional, so just use whichever is least confusing.  I don't know why it is that way.  Probably a decision someone who worked on the code at one point made.

Rad wrote on Jul 13th, 2009 at 9:15pm:
hey MUST make their source available, right?

They have to make source available any GPL code they have changed and want to distribute in binary form.  The could choose not to provide the source for anything they have written themselves (and they do write a lot of code) and I don't think they have to supply the source for GPL code that they merely repackage and distribute (like the Linux kernel, for example.)

So, they have to give some of it away.  They are nice enough to give it all away in a fairly easy to use form.

Rad wrote on Jul 13th, 2009 at 9:15pm:
If not, and they stopped, CentOS would be outta business, right?

Correct. 

Although CentOS is not "in business."  It is a community effort that the people responsible make no money from.  In fact, I wouldn't be surprised if it costs them money to cover hosting bandwidth and such.  But, yes, there would be no CentOS if Red Hat sources were not publicly available.

Rad wrote on Jul 13th, 2009 at 9:15pm:
Why doesn't RH just sell support subscriptions?

Essentially, they do.  You get a free copy of the code when you buy support.

Rad wrote on Jul 13th, 2009 at 9:15pm:
Anybody can take their source and compile it, right?  ...I don't get why anybody would pay hundreds of dollars for an OS they can get for free .. follow me?

It is legal for anyone to compile the code and use it.  Actually doing it is another matter.  I have no interest in trying to compile an entire OS from source and install it.  That's why CentOS is so cool - they do the hard work for you.

In practice, the people who pay for Red Hat is probably a small percentage of the people who use it.  Many individuals and businesses use CentOS or Fedora instead. 

However, for some businesses, Red Hat is the better choice because you get support from the vendor.  This is key for small businesses who need constant hand holding, bigger businesses who need expertise to get the software deployed organization wide, or any businesses who needs someone to blame when things go wrong.  I'm always amazed at how little expertise some of the bigger tech companies keep in-house.  Many of them are content with some lower-level admins and lean heavily on vendor support.

Rad wrote on Jul 13th, 2009 at 9:15pm:
Have you heard anything about RH sppt? Are they good? Okay? Suk?

I've never dealt with them personally, but I've heard good things.  The guys that taught the class/test for my RHCT were solid.  They knew their stuff and were very professional.
 
WWW  
IP Logged
 
Rad.in.UbuntuVM
Radmeister
**
Offline


Rad in Ubuntu 9.04 Jaunty
Virtual Machine

Posts: 92


Back to top
Re: Continued: Linux and Shell Scripting
Reply #29 - Jul 14th, 2009 at 12:54am
 
MrMagoo wrote on Jul 13th, 2009 at 10:35pm:
It is legal for anyone to compile the code and use it.Actually doing it is another matter.I have no interest in trying to compile an entire OS from source and install it.

you make it sound difficult. Isn't it simply a matter of launching the compiler, pointing it to/at the source code file and clicking the 'Compile' button? .. so to speak. I mean, if it's done via command-line, then there's obviously no button to click.

Hmmm. I noticed your double-spaced sentences are turning into no spaced sentences when I mark-n-quote them. Must be a bug.

does the f option have to come last in a series of options for tar?
 
WWW  
IP Logged
 
Pages: 1 2 3 
Send Topic Print