Linux - NewbieThis 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
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
lets say you work in car insurance and you have a member db2 database to load on a mainframe with 2 million members and because of queue restraints you can only load 100,000 at a time. you can either set your alarm to wake up every hour between midnite and 6am.
or you can create an ftp script (albeit insecure since it has embedded username/password -- mainframe doesnt provide ssh) and schedule it via cron.
Creating LXC containers, deploying software over the network, software building, basically (as Habitual already pointed out) anything that involves typing (more than one command) and has to be done more often.
Not only makes scripting your work faster, but also less error prone (if done right, of course).
I came across this thread and got curious about something. I am new to Linux and I am planning to try out a few different distros to see which one I like, I've already tried Mint and I liked that one. But one thing I dread with trying out new distros is every time you switch distros you're going to have any programs you had installed in the first distro disappear. Would it be possible to do a script so that when you got into a new distro you could have it automatically download and install the packages you had on the other one, so you don't have to go through the installation procedure a bunch of times? Thanks
I came across this thread and got curious about something. I am new to Linux and I am planning to try out a few different distros to see which one I like, I've already tried Mint and I liked that one. But one thing I dread with trying out new distros is every time you switch distros you're going to have any programs you had installed in the first distro disappear. Would it be possible to do a script so that when you got into a new distro you could have it automatically download and install the packages you had on the other one, so you don't have to go through the installation procedure a bunch of times? Thanks
I'm not aware of any clean and automated way to do this, I follow some processes on my own to maintain continuity. You may want to check out this thread How long do you stick with a particular distro? there's some discussion there about what person's do WRT hopping from distribution to distribution.
The way I migrated was I booted via LiveUSB thus allowing me to install onto the USB things I needed to accomplish my functional mirroring, and I also keep my data on separate drives from my installation. I noted the alterations I had to make on the Live distro to get it doing all I needed/wanted from my old and then when I did a full wipe/install I knew the things to install/set-up and also knew how to do those things in the event that they weren't all simple tasks.
I came across this thread and got curious about something. I am new to Linux and I am planning to try out a few different distros to see which one I like, I've already tried Mint and I liked that one. But one thing I dread with trying out new distros is every time you switch distros you're going to have any programs you had installed in the first distro disappear. Would it be possible to do a script so that when you got into a new distro you could have it automatically download and install the packages you had on the other one, so you don't have to go through the installation procedure a bunch of times? Thanks
It depends on what distros you're switching between and what programs you're installing. If you're talking about building from source, you could script that, but you would need to add a bunch of error handling since the library versions would differ and you could run into problems on certain distros. If you're talking about installing from the standard repos, you script pretty much all of that, provided you stick to distros with the same package manager (apt, yum, zypper, etc.).
I came across this thread and got curious about something. I am new to Linux and I am planning to try out a few different distros to see which one I like, I've already tried Mint and I liked that one. But one thing I dread with trying out new distros is every time you switch distros you're going to have any programs you had installed in the first distro disappear. Would it be possible to do a script so that when you got into a new distro you could have it automatically download and install the packages you had on the other one, so you don't have to go through the installation procedure a bunch of times? Thanks
This is indeed possible, providing that you switch between distros that have the same base distro (for example, both are based on Ubuntu), so that package names are consistent between distros and the same package manager is used, and of course provided that the installed packages are available in both distributions (for example, the Mint tools are not available in Ubuntu's repositories).
So, it is quite simple to get a similar setup on KWheezy and Debian, but trying to do the same when switching from Debian to, for example Gentoo is far from trivial.
Thats excellent info from all thanks...so how do i exercise scripting on a couple of servers running slackware and a few laptop workstations? can anybody give me a good example on what i could be doing to become more familiar or should i pick up a good book on say ...python scripting?
Well,.. if you are comfortable programming, then Python is a good start. (I suggest 'fabric' for automation in python http://www.fabfile.org/) But if not, Bash is the command shell most GNU/Linux distro's use, and it is indispensable to know how to use it.
Luckily there are hundreds of Bash resources, the more famous beginner version being this:
Python is more than a "simple" scripting language, it is a fully fledged programming language that can be used for much more than writing some automation scripts. While you can use Python to automate system maintenance and automation (and there is nothing wrong with it if you do), usually Bash is used for that type of tasks.
If you want to learn Python, go ahead, the Python website is full of tutorials and links to freely available books, Python is a powerful language.
If you want to learn Bash instead (and don't get me wrong, you can write quite complex programs with it, look for example at Slackware's package management tools or installer) have a look here: http://tldp.org/LDP/abs/html/
It contains all you need to start Bash scripting.
What you actually try to automate is up to you, begin with something simple that you want to automate and just go ahead. If there are questions not covered by the documentation, the Programming subforum at LQ is full of knowledgeable and helpful people.
As others have suggested automation takes many shapes and forms as to what is automated. In regards to what language you should use I'd say become familiar with a variety of languages (to an expert level) such as bash, awk, Python/ruby to name a few. Bash is more than just bash. It is the entire coreutils toolset as well as any program that properly reports POSIX standard exit codes. The power is not only in bash itself but also in the plethora of tools it can be used to execute.
Here's a thread I like to point people who want to know more about system administration.
When you get a few languages under your belt you'll begin to infer the strengths and weaknesses of each language. When you get to that point you'll know how to use the right tool for the job.
I know what you guys have said, and what your opinions on certs are...just wondering if RHCSA is an entry level certification...it appears to be. and as pointed out earlier,i dont expect to get a job with a cert...i just want to study with a goal in mind...while getting practical experience as a hobbyist.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.