Archive for December 5th, 2009

Submit to StumbleUponDigg ThisShare on TwitterSave on Delicious

The Complete Steps to Create and Run a Linux Script to Run Linux Commands
By Clyde E. Boom

Creating and running a Linux script to automatically run a series of Linux commands that you commonly run is easy!

With a Linux script, you put a series of routinely run commands in a text file, and then run all of them by simply typing in the name of the file and pressing Enter.

Linux Script Example to Create a Script to Automatically Run A Series of Linux System Administration Commands2455513753_282aa586b7

Follow along with the steps in the example below to create and run your first Linux script!

1. Run a Linux text editor.

2. Put the following text at the top left of the text file (indented below for emphasis):

#!/bin/bash

This indicates that the text file is a Linux script file.

Press Enter twice to have a blank line below the line above.

3. Put the Linux command(s) in the script file.

The Linux commands below are used to provide an example. You can put any commands in a script.

The Linux commands below will: clear the screen, change into the /etc directory path, and then show the current path with the Linux pwd (path to working directory) command.

Then provide a long list of the fstab file (to show you that it’s there) and then change into your home directory (represented by the ~ symbol) and then show the path of the current directory.

The Linux echo command is not required, but has been put in the file to show the progress of the execution of the script.

Also, you don’t need to indent the commands below in the Linux script – they are just indented here for emphasis.

clear
echo The screen has been cleared

cd /etc

pwd

echo This is the etc directory

ls -l fstab

echo This is a long listing of the fstab file

cd ~

pwd echo Now in my home directory

Linux Commands Training Tips: A Linux script can contain hundreds of lines of text if necessary – and also include complex programming logic, such as if . . . then statements.

4. Save the text / script file with a meaningful name to create it and by give it a name.

For example, if you want to list files in a few directories, call the file: listdirs

5. Run the Linux chmod command to change the permissions of the file and make the Linux text file “executable”.

In our example, the file is named: listdirs

Below is a Linux chmod command example for running the chmod command to change the permissions of the Linux script file – and to make the listdirs text / script file “executable”, so that you can run the script file in the same way as you run a command.

The $ (dollar sign) below is the Linux command line prompt. Don’t type in the $ (dolar sign), type in the command that appears at the right of the $ prompt.

$ chmod u+x listdirs

The Linux command above is chmod and it is being used to assign the x (executable) permission to the u (user) of the file with: u+x and the script file name is listdirs.

Running a Linux Script to Run System Administration Commands

To run a Linux script (that is in the “current” directory), such as the listdirs script, simply type in a period (dot) and a space and then the name of the file and press Enter.

$ . listdirs

The concepts and Linux command examples shown above work in Red Hat, Ubuntu, Fedora, Slackware, and Debian Linux – and also ALL Linux distributions.

By the way…do you want to learn exactly how to use Linux and run Linux commands for Linux System Administration and get real, practical Linux training experience by running hundreds of examples of Linux commands?

Just click to download my free new Linux commands training course book and Linux audio podcast (.mp3) files here: Linux Commands Training Mini-Course

Clyde Boom says “Learn how to use Linux commands with easy, self-paced Linux training materials that show you how to run hundreds of examples of the essential Linux System Administration commands – and get that new and better job, promotion, raise – or keep your current job!”

You can get your instant access to my free Linux commands training course at:
http://www.LinuxCommandsTrainingCourse.com

Tags: , , , , , , , ,

Top Social Network Platforms

Submit to StumbleUponDigg ThisShare on TwitterSave on Delicious

Top Social Network Platforms
By Jonathon R Boone

If you are hoping to produce a social network and you are in a rush, then you should visit a website like Ning. Ning is the first larger hosted social networking site that comes to mind. If you are one of those who wish to have more control of their web site, that is, having your own personalized domain name, controlling the design and of course, the brandmark, then the advisable way is to run one of the off the shelf networking scripts available.

There are quite a few social networking scripts on the market these days, both free and paid for. The reality is that only a handful are worth the money.

After a brief community survey amongst social networking webmasters, it didn’t take long to figure out who was running what. From our tally we determined these four social networking sites to be the top five currently on the market.

DZOIC Handshakes offers up one of the foremost open source community programs for this year, so there is very little doubt about the usability of this software. For the most part, Dzoic Handshakes is a potent piece of computer software that dishes up article writing, instant messaging, community, video, music plus tons more. In fact, it is one of the most versatile pieces of software that provides pretty much everything you need to start a social site right out of the box.

Dzoic Handshakes works on a runs on a Linux, Apache, MySql and Php environment is simple to upload, install and configure. Having very little php skill, you can get your social networking script up and functional in no time.

PhpFox is possibly Dzoic Handshakes strongest competitor and designed with similar functionality. It is awesome platform perfect for just about any niche. With PhpFox, you can tap into a huge community of adept PhpFox users and utilize their talents. Features in the software include live chat, Videos, Advanced profile editing, video and image tagging, RSS feeds plus much more. You have endless possibilities with this software and like Handshakes, it is 100% encryption free.

PhpFox works on a runs on a Linux, Apache, MySql and Php environment like handshakes.
What are people saying about PhpFox? Find out here.

Social Engine, is 100% open source, is a modulure based, social networking software that operates on the Php, MySql,Apache and Linux environment. You can easily customize Social Engine and the Social Engine script writers have gone to surpassing lengths to get Social Engine user friendly and easy to customise. Using thoroughly anotated and unencrypted source code, you should have no problem navigating your webpages. The Coders also went out of their way to supply fully commented HTML templates for all the pages of your social network.

The only major downside to using the Social Engine is that it can get expensive. If you were to simply purchase the bare bone script you would not have enough to make a sound social network. You would have to purchse additional modules which can get expensive.

Get more reviews on the Social Engine Networking script here.|See what other people are saying

Dolphin 6 – Smart Community Builder is versatile social networking script that boasts itself as being free. We all know all great things come with a catch. Boonex has licensing features that allow you to slowly get away from their control for a small cost. The fees are dependent upon the duration of the licensing. Boonex comes with stockpile of bells and whistles. Bells and whistles include 100% AJAX Forums, Photo Sharing, Video Sharing, Music Sharing, Blogs, Polls, Search Events, Groups, Mailbox, Friends, Customizable Profiles, Powerful Admin Panel, Design Templates and Languages!

Dolphin – Smart Community Builder is based on php and operates on the Php, MySql, Apache and Linux environment

John is a fulltime social networking consultant who helps newcomers get their social networking websites off the ground

social networking software reviews

Tags: , , , ,
Submit to StumbleUponDigg ThisShare on TwitterSave on Delicious

Basic Linux For Ease of Use and Management of a Hosted Website – Getting Started!
By Mike Tremell

Welcome to the beginning of a path to simpler website administration!

This article is the first in a series aimed at the average user with the average hosted website; someone without a vast 180px-KN-Servers2amount of hyper-technical knowledge about the guts of the internet. We will see that utilizing the more “complicated” part of the hosting provider’s service can be easy and can make your website management easier as well. I will provide you with a basic road map to simple Linux utilization that, I believe, will both benefit, please and, ultimately, empower you to better manage and amplify your site’s potential!

As we all know, with the proliferation of user-hosted websites in our age, the market has driven most hosting services to provide users with more user-friendly interfaces; windows, or browser, based menuing systems with simple and easy to understand layouts.

This is a good thing, but it’s also a bad thing. One could make the argument that the simplification of hosted website management through the use of these interfaces makes it possible for the average person to easily set up and manage their own website or e-business. This is true. In fact, it’s one of the main reasons that the web hosting industry is experiencing a boom. Consumers demand ease-of-use from merchants and simple picture-menu based setup and maintenance systems fulfill that demand.

So how can this be a bad thing?

There are a multitude of reasons, but the one I’ll be addressing here is, coincidentally, the exact same thing: Ease Of Use! What most people don’t realize at first (but soon become aware of) is that the “Ease Of Use” supplied by these point-and-click-simple solutions, more often than not, make a lot of simple tasks extremely difficult, if not impossible!

The double-whammy is that they essentially “mystify” the underlying operating system (that place where the work actually gets done) and lock most people into a cycle of endless forum-searching or email-tag with customer support (and experienced Linux users) where they find, mostly, answers that assume they already possess whatever basic knowledge they need to complete the task at hand. I’m not saying that any of these folks are unfriendly or unwilling to help, just that the average user ends up no better off in the end and has to go back to… the windows-like menuing system.

The good news is: You don’t have to settle!

Given the right circumstances, you can enhance your ability to maximize the potential of your website, and, ironically, increase your “Ease Of Use” by making use of that underlying operating system.

By learning just a few of the basics of Linux (the most popular operating system for most web-hosting solution providers), you can dramatically increase the ease with which you can maintain, and even optimize, your website.

Below, we’ll go Point-by-Point, with “Tips” along the way, toward adding use of the Linux operating system to your bag of tricks. The de-mystification begins!

Point Number 1: Don’t let any roadblocks you hit discourage you. What you’re about to accomplish is within the realm of absolute possibility. You CAN use Linux to maintain your website, enhance it, optimize it and much more. None of this is beyond your ability. Societally perpetuated self-doubt, mass-belief that it’s all just too complicated and the pervasive notion that Linux is comprehensible only to computer science majors and “techies” are myth’s and falsehoods.

You can master Linux as easily as you can master your ABC’s. If that seems like over-simplification, believe me when I tell you that it’s not. Remember how much easier it was to remember LMNOP than it was the rest of the alphabet? In simplistic terms, you’ll be learning how to help yourself by learning how to use Linux to your advantage in much the same way. We’ll start with the parts that come easily, and the rest will fall into place over time, seemingly without effort!

Point Number 2: In order to make any of this work, your service provider will have to offer you the option of using a “shell account.” This is the most common terminology for direct access to the underlying operating system. “Shell access” is also commonly understood. If you are already being hosted, be sure to use these terms when requesting the access you’ll need. All service providers understand what a “shell account,” or “shell access” is and will be able to let you know, immediately, whether or not they offer their users that option.

Tip: If you are in the consideration phase, and looking for a hosting provider, be sure to ask them if they offer you the option of a “shell account,” or “shell access.” It’s your call in the end, but, if they don’t, I would advise that you continue your search for a provider elsewhere.

Tip: Most providers offer “shell accounts,” or “shell access,” but they don’t make a point of letting you know. In my experience, it’s never anywhere near the top of the list of features the hosting provider offers, and, most times, you have to go to the support page, or elsewhere, to find out. You just need to ask. If it’s something they offer, they’ll give it to you (however grudgingly); usually with simple login instructions. Hosting providers generally don’t like the thought of “regular” users mucking about with the underlying operating system, so they generally don’t make it a point to let you know you have this option!

Point Number 3: Now you’re going to need to get to your shell account. This is a piece of the puzzle that most service providers will assume you know how to do. We’ll assume for the moment that you don’t. For our purposes here we’ll assume your provider is a company named XYZ.com and you already have access to the internet and have that connection active when you connect to your “shell account.”

There are certain things that you’re going to need in order to access your shell account; all of which are free. Some you’ll have to get yourself and some you’ll most likely have to request from your service provider.

Most importantly, you’ll need your connection information. You will get this from your service provider. It should include:

1. The host name or IP address of the server you’ll need to connect to in order to access your account (e.g. webhost.XYZ.com or somecrazyname.XYZ.com). You’ll almost never be given an IP address exclusively. Your service provider should, however, include this information along with the server name (e.g. webhost.XYZ.com – IP Address: 192.68.224.176). Having an IP address to connect to can be advantageous if, for some reason, you can’t reach the server via the host name.

2. Your login information. This will simply be a user name and password.

3. The method by which you can access your shell account. Generally this will be via “SSH” (Secure Shell), but some hosts still use “Telnet” (Telecommunication Network

‘t let the definitions I’ve included in parentheses put you off. They’re simply provided for completeness and shouldn’t concern you at this point. Their strict “definitions” may never ever concern you – They don’t concern me and I’ve been in the business for well over a decade!

Basically, the difference between the two connection methods is academic. Telnet sends information over the internet as-it-is. This is one of the reasons most providers use SSH. SSH sends information over the internet in “encrypted” form. That is, Telnet is an “unsecure” protocol, while SSH is considered “secure.” It’s much harder (if not nearly impossible) for someone to hack into your connection and “see” what you’re typing if the information is encrypted. Encrypted information is protected. Unencrypted information (what you’ll be sending if you use Telnet) can be read (by the proper hacker) as if he or she were looking over your shoulder watching you type!

Tip: Don’t accept Telnet if it’s offered as a connection option. Insist on SSH. If SSH is not available from your provider, there are other options you can pursue, but they’re beyond the scope of this article.

Next, you’ll need a method by which to connect, using the information given to you by your hosting provider. This is simply going to be some software “client” that you’ll use to connect. Many SSH clients are available for free and can be downloaded at various freeware sites on the internet (Use any search engine and simply type in a search for “SSH client freeware download.” You’ll be surprised at the number of options available!)

Tip: Don’t pay for an SSH client unless it makes you feel better. There are several reputable and highly effective clients available for free. Almost all work right out of the box (just start them up and look for a button that says “new connection,” or something similar, and then you’ll be presented with a screen into which you can type in the host name, user name and password information you received from your hosting provider. Just click connect and you’re logging into your “shell account!”

Point Number 4: Now, strangely enough (with most providers), you’ll be presented with a “menu screen” once you login to your “shell account.” This will generally provide you with several options such as editing files, sending email, uploading or downloading files, etc.

A text-based menu is generally fairly easy to follow. Options are presented on a numbered menu (possibly with letter shortcuts in parentheses alongside), you select the number (or letter) of the option you want to use and then you do whatever that is until you exit and come back to the menu. A simple menu might look like this:

—- Welcome to XYZ.com Shell Access Menu —–

1. Edit Files (e)

2. Send Email (s)

3. Upload Files (u)

4. Download Files (d)

5. Linux Shell (l)

6. Quit (q)

Enter your option

Tip: If you use any option and it isn’t made obvious how you can get back to the menuing system, you can generally get back there by “killing” whatever program you’ve launched by selecting your option. This can usually be done by typing one of the following “control-character” sequences. ctl+c, ctl+x, ctl+v, ctl+d. The key combinations described here are simply the typing of two keys at once (denoted by the + symbol), so for ctl+c you would type the “control” key (usually “ctl” or “ctrl” on your keyboard) while simultaneously typing the “c” key. Just type them both at the same time. Nothing to it!

Please note that all of these options may disconnect you completely from your server and should be used only after you’ve saved any work you’re doing.

Not to worry; if you do get disconnected, all you need to do is connect again. Of course, any and/or all of these options may do nothing at all. If you just “need” to disconnect and can find no remedy in your “shell account,” you can always take the guaranteed step of closing your SSH client.

Now you have arrived!

This part of the lesson is coming to an end, but your journey has just begun. At this point, fool around with the various menu options and try out the various features of your “shell account.” Use them with caution, as you would when interfacing with your window-based menuing system. Try to keep your actions non-destructive (e.g. If you’re going to edit a file in a foreign editor, make sure to back it up, or copy if off, first, etc).

If your hosting provider’s “shell account” is literally that, you’ll end up at a “shell prompt” after connecting. Take some time to investigate. For now, stick to using “info,” “help” or “man” (for manual) commands to learn about your environment. You’ll know you’re at a shell prompt immediately. It may look something like this (But, there’s no mistaking it for a menu!)

/home/user/public_html >_

Practice with the skills you’ve gained so far. You’ll find, with time that they will become second nature. Of course, we’re only part of the way there now, but, as this article is a “Beginning,” you have accomplished your goal.

Remember, with practice and patience, you can learn a thing or two about Linux as you explore your new environment. Be cautious, but have fun. It’s one of the best ways to learn!

“Ease Of Use” in managing your website will take on a new meaning for you as we continue. Hopefully, it has already!

If you’re already slightly farther ahead in the game, or would simply like to take some steps to get your existing, or in-progress site notices, my website might be worth your while to check out.
But, that may be for later.

Mike Tremell – (c) 2007

If you have any questions about this article, or you’d like to be kept informed of updates to this series, please feel free to email me and I will include you in a mailing to announce future updates. Please also note that I respect your privacy and your email will not be resold or used for any other purpose; I do not send out unsolicited email or do any bulk email marketing.

Having trouble passing computer certification test? Look no further than this ebook on Computer Certification Success [http://www.web-advantage.org]!

Tags: , , , , ,
Back to top