skip to main | skip to sidebar

OPEN SOURCE

Linux for Better life

  • Home
  • Trik-Tips
  • Free Template
  • Blogger Hack
  • Free Ebook
Showing posts with label linux. Show all posts
Showing posts with label linux. Show all posts

Aktivasi Free Blog Hosting @OpenSUSE-ID

Untuk semakin meningkatkan awareness para pengguna OpenSUSE, Komunitas OpenSUSE Indonesia secara resmi meluncurkan fasilitas Ngeblog Gratis dengan nama domain opensuse-id.org.

Feature dan layanan terbaru ini diluncurkan melengkapi website utama, mailing list, forum, support online, tutorial dan planet dan rencananya akan dilengkapi juga dengan pembuatan mirror OpenSUSE. Yang terakhir masih dalam persiapan dan mudah-mudahan dapat diaplikasikan dalam waktu yang tidak terlalu lama.


Perlu diingat bahwa Blog@OpenSUSE-ID tidak mengharuskan anda menjadi pengguna OpenSUSE. Kami tentu sangat menghargai dan menganjurkan penggunaan OpenSUSE sebagai sistem operasi komputer yang handal, powerful, bagus, indah dan gratis :-) namun kami menggunakannya karena kami ingin dan kami percaya, bukan karena terpaksa dan bukan karena kami tidak mampu membeli lisensi (iya juga sih karena lisensi sistem komputer tetangga sebelah mahal banget :-) )

Dari sisi komunitas blogger, kami berharap penyediaan layanan ini akan semakin meningkatkan jumlah blogger di Indonesia. PestaBlogger tahun 2007 mencanangkan adanya 1 juta blogger di Indonesia tahun 2008 dan meski mungkin tidak banyak menyumbang, kami berharap Komunitas OpenSUSE Indonesia menjadi bagian yang meningkatkan jumlah blogger di Indonesia.

Tertarik ? Ayo meluncur dan ngeblog bersama OpenSUSE-ID


Posted by MALIK 0 comments

Labels: linux, Open SuSE

UNIX and LINUX part 12


Tracked aliases
Tracked aliases are not true aliases. A tracked alias is the actual command name and the full pathname used to access an existing command. It is called tracked alias because the path is aliased for the command name and the new alias tracks directly to the command. This keeps the shell from having to search the entire PATH for a command, thus providing faster command execution.
You can turn command tracking on by using the set command. Type
cj> set -o trackall

to inform the shell to track all commands issued to it. For example, the following sequence of commands illustrates the automatic tracking of commands.
cj> set -o trackall
cj> alias ls # list alias of ls command
ls alias not found # no alias exists for ls
cj> ls # execute the ls command
...
cj> alias ls # list alias of ls command
ls=/bin/ls # tracked alias has been set to full path

You can track individual commands by using the -t option. For example,
cj> alias -t ls

would cause the same results as the above steps. But the shell would not automatically set every command you issue to a tracked alias.
RETURN CODES
Alias returns a zero (true) unless a name is given that has not been set to a string.
APPLICATIONS
The alias command is used to create shorthand versions of longer commands. It is very useful for hard-to-remember commands and for those commands you use repeatedly throughout the day. Remember to place your aliases in your .profile or your ENV file (.kshrc) so they are set each time you log in.
The unalias command is used to remove previously set aliases.
TYPICAL OPERATION
In this activity you use the alias command to create various aliases. Begin at the shell prompt.
1. Type alias "I= -F" and press Return.
C Shell
Type alias I "Is -F" and press Return.
2. Now try your new command by typing I and pressing Return. Notice the output of your l command is a multicolumn list with the executable (*) and directory (/) files being flagged.
3. List all aliases you have set by typing alias and pressing Return.
In this activity you use the unalias command to remove the previously defined l alias command. Begin at the shell prompt.
1. Remove the l alias by typing unalias I and pressing Return.
2. Type alias I and press Return to list out your l alias. Notice the l alias is no longer defined.
3. Turn to Module 64 to continue the learning sequence.

Posted by MALIK

Labels: alias, application, code, command, linux, path, unix

UNIX and LINUX part 10


SYSTEM DOCUMENTATION
There are many different documents produced by AT and T and other UNIX developers. The primary documents for each UNIX System are the Reference Manuals and Guides. These documents provide you with specific details on the UNIX System you are using. One other document that most users ignore but that is extremely important is the Release Notes for UNIX and all related software. Release Notes provide insight to changes, quirks, problems, and compatibility issues relating to the new release of the software. It will be to your benefit to locate a copy and discover what your release of UNIX holds in store for you.
The User's Reference Manual and the User's Guide describe the basic utilities and software of the UNIX System. The Reference Manual describes each utility that is available on the UNIX System. The Guide provides an overview and tutorials on the more common and complex UNIX utilities.
Illustrated UNIX addresses both of these areas to provide a tutorial and a reference manual in one book. It demystifies the guru language of the standard reference manuals and organizes the tutorials into a useful sequence that can later be easily referenced.

Posted by MALIK

Labels: AT and T, documentation, linux, system, unix, utility

UNIX and LINUX part 9


Each file has one inode number that points to that file's index node, or inode for short. A file has one and only one inode, even though it may have multiple filenames. The filenames are all linked to the same inode by the directory entries. An inode contains the following information:
owner (user ID)
type (directory, ordinary, block special, character special, or pipe)
access permissions (user, group, others)
access times (last modification, last access, last inode modification)
number of links size in bytes (number of filenames stored in directories)
disk addresses (Multiple entries point to the data of which
- some entries point to data blocks
- other entries point to a single indirect block
- other entries point to a double indirect block
- other entries point to a triple indirect block)
Limitations
The current limit on a file size is over 4 gigabytes, based on 1024-byte file system blocks, usually more space than is available on the entire system's disk drives. The name of a file can only be 256 characters.
Problems
On a multiuser system with thousands of files, there is the possibility that the filename has been used previously by another user. This does not pose a large problem, because most users have their own private directories, but it must be considered in publicly used directories.
SPECIAL FILES
Special UNIX files are pieces of computer code that interface with the UNIX kernel. There are two types of special files: device drivers and fifos. Both are interfaces within the UNIX kernel, a part of the I/O subsystem.
Device drivers are used to communicate with and control peripheral devices attached to your UNIX System, such as printers, terminals, disk drives, or tape drives. Device drivers may be block or character special, referring to how the driver handles I/O to and from a device.
Fifo (Pipes) are used to join two or more UNIX processes together allowing the streaming of data. Streaming data means that data flows from one program into the next without being stored on disk. Fifo special (first-in first-out), or named pipes, allow unrelated UNIX programs to exchange information.
Device Drivers
Device drivers are block or character special files. They are low-level routines that reside in the system kernel where they interface to peripheral devices, such as terminals, printers, disk and tape drives, connected to the computer system. They perform I/O tasks to and from a specific type of device. UNIX device drivers are interfaces that make devices appear as ordinary files when performing I/O functions.
Block-type drivers read and write in blocks of data, resembling random access storage. A block is usually 512 or 1024 bytes, depending on your system's BSIZE constant stored in /usr/include /sys/param.h.
Character-type drivers read and write a single byte of data, often referred to as raw devices. Most of the device drivers on a UNIX System are character special.
Pipes
A pipe is a UNIX file that takes the output of one process and provides it as input to the next process. A more internal view of a pipe would be that data is transferred between processes in a first-in first-out sequence. The pipe also synchronizes the execution of the surrounding processes. The first process must execute and begin output before the next process can begin its execution.
The most common use of pipes is to connect multiple UNIX programs together to form a pipeline. A pipeline feeds information from one program to the next.
When executing multiple UNIX commands, pipes may be used between the commands to create what is referred to as a pipeline command. Likewise, if data is to start in an original state at the source and be manipulated by commands along the way to its destination, then pipes must be used to connect the commands together so that the data flows to the destination. For convenience, the entire command is called a pipeline.
Since the commands are changing the data along the way, they are referred to as filters. A command must be capable of being a filter for it to be used in a pipe. A filter can read from standard input and write to standard output. The pipe passes data unchanged while a filter manipulates the data as it is passed down the pipeline.
Enter the following command at your shell prompt and press Return:
cj> grep :0: /etc/passwd | nawk -F: '{ print $1 " "$5}' | sed 's/://g'
root Admin. - super user
sync File system sync
dgn Diagnostics

The output is the first and fifth fields of lines from the password file that contained the :0: string, which should be all logins with root user ID permissions.
The same results could have been accomplished using temporary files, but this is very inefficient and clumsy.
cj> grep :0: /etc/passwd > TMP1
cj> nawk -F: '{ print $1 " " $5 }' TMP1 > TMP2
cj> sed 's/://g' TMP2
root Admin. - super user
sync File system sync
dgn Diagnostics
cj> rm TMP1 TMP2

THE UNIX SHELL
The shell (ksh) is a very powerful and dynamic UNIX utility that functions as the UNIX command interpreter. It is the primary user interface to the operating system (kernel). The shell is a command language and a programming language. As a command language it can be used to communicate interactively with the kernel. As a programming language users can write shell scripts to solve simple to complex problems.
The shell is probably the most sophisticated UNIX utility. It can read from your terminal or from a file. Thus is can be interactively programmed or programs can be stored in files.
The following is a typical sequence of events when a user interacts with the shell as the primary user interface:
1. User logs in to the system.
2. The shell prompts for input (a command).
3. User types in command and presses Return.
4. The shell searches for program; if found, executes it.
5. Program runs; user may interact with program.
6. Program exits; user may have to exit the program.
7. The shell prompts for next command; return to number 4 above.
8. User types exit, logout, or Ctrl-D to exit shell.
9. The shell logs the user off the system.

Posted by MALIK

Labels: device, driver, linux, open source, operating system, programming, unix

UNIX and LINUX part 7


PORTABILITY
One of the most sought after features UNIX possesses is portability. Portability is the ability to rewrite the operating system for a different vendor's hardware without a major rewrite effort. UNIX is highly portable and has been ported by many hardware vendors to their computer hardware. In fact, every computer vendor has a UNIX or a UNIX-like system ported to their hardware - a milestone that no other operating system can claim.
There are two main reasons UNIX is a prime system for porting from hardware to hardware. The first is that the kernel provides an interface between the hardware and most of the nonkernel UNIX software. When UNIX is ported to another hardware platform, only the kernel requires major modifications. Since most of the UNIX software interfaces with the kernel and not the hardware, the software is hardware independent and does not require much, if any, modification when it is ported to a new hardware platform.
The second reason UNIX is easy to port is that the majority of the UNIX operating system is written in the C programming language. Most operating systems are written in the hardware vendor's proprietary assembly language. This makes it very difficult, if not impossible, to port their operating systems to a different vendor's computer.
Benefits
Portability allows the customer to choose the vendor and not be locked into that vendor's hardware and software environment. It also provides the user with a broad base of application software that can be used on hardware from different application vendors.
The porting of an operating system creates a standard software environment across a broad range of computers, ranging in size from micros to supercomputers. This cuts training time dramatically and increases overall productivity. It also reduces support costs and redevelopment costs.
PORTABLE APPLICATION SOFTWARE
The UNIX System provides a standard application development environment that allows for easy porting of application software. The C programming language is a big asset to the porting of software between different UNIX machines.
The ability to port software to many systems easily provides application software vendors with a much larger market without the headaches of multiple proprietary environments. Customer training requirements are reduced and the training of internal personnel is minimized. The number of support people needed is not increased because of different knowledge base requirements, but because more software is being sold. Development can spend more time on enhancements instead of ports to unknown, proprietary architectures. Once a customer has bought a product on one UNIX machine, the customer can purchase a different vendor's UNIX machine and be able to use the same applications without having to retrain personnel. As you can understand, portability is a very important issue for many computer users.
JOB CONTROL
Job control on UNIX is the ability to control which job is executed in foreground, background, or is suspended.
* Foreground execution is considered normal interactive command execution. The command is entered from the keyboard. The shell waits until the command completes execution, then the shell prompts for another command to execute.
* Background execution is considered batch processing. A command is entered and detached from the terminal. The shell can continue interactive command processing.
* Suspended jobs (processes) are commands that have been placed in a suspended state. They are not being executed in background or foreground.
Job control allows you to suspend a foreground or background job. A suspended job can be moved to background or foreground. Background jobs can be brought to the foreground and foreground jobs can be placed in the background.
Using job control can increase the productivity of a user by allowing multiple tasks to be juggled back and forth between background, foreground, or a suspended state. For example, a user can edit a source file while executing the compiled program, thus watching the functionality of the program and making changes while suspending the program.

Posted by MALIK

Labels: code, free, linux, open source, operating system, unix

UNIX and LINUX part 6


COMMUNICATING WITH OTHER USERS
UNIX provides multiple ways to communicate with other users. There are commands to communicate interactively or by electronic mail (E-mail). The following is a brief overview of some of the more common commands used to communicate with fellow users.
WRITING TO A USER
The write command allows you to write to a user that is currently logged on to the system. The following steps show how to "talk" to a user with write.
1. First you must find out who is available for you to write. Type who and press Return. This will display who is currently on the system. Select a user to write to and continue on to the next step.
cj> who
bill tty05 Jan 11 08:41
nancy tty07 Jan 11 08:03
mylogin tty11 Jan 11 09:05
nasser tty18 Jan 11 07:49
smr tty23 Jan 11 09:11
tlp tty09 Jan 11 07:38

2. Type write bill and press Return. Now type a message you would like to send to bill. When you finish writing your message press Ctrl-D.
cj> write bill
Hi Bill,
This is Robert. I finally got my UNIX login and am trying to
annoy all other users so they will log off the system and
response time will improve. Have a great day and LOG OFF the
system now!.
^D

NOTE:
While you are typing your message you may see text intermixed with what you are typing. This is probably one line of a response message from the person you are writing.
RECEIVING MESSAGES FROM WRITE
If someone is sending you a message from write, you can perform the following steps to respond.
1. First you will receive a message and a beep when someone writes to you.
Message from bill tty5...

2. Respond by typing write bill and pressing Return. From this point forward you continue your communication as if you had initiated the conversation.
SENDING MAIL
You can send mail to a user by using the mail command.
The mail command reads in a message and sends it to a mailbox for the specific user. The following steps show how to send a simple letter to a user on your local system.
1. First you must know to whom to send the letter. To retrieve a list of all users on your local UNIX System type nawk -F: '{print $1" "$5}' /etc/passwd | sort | more and press Return.
2. Select a user name and type mail nancy and press Return. Now you may type the letter you wish to send to nancy. After you finish the letter, press Ctrl-D to send the letter to nancy. Replace nancy with the name of a user on your system.
RECEIVING MAIL
To receive mail, a user must first send mail to your user name. If no one likes you and you never receive mail you can always send mail to yourself. This is very common practice; it provides an on-line reminder service. The following steps show how to read any mail that may have been sent.
1. Type mail and press Return. Notice the message you requested your system administrator to send you is displayed. If there's no mail you probably have a very busy system administrator.
2. The mail utility has a help feature that provides some insight to using it more effectively. Type ? or help and press Return. Notice a screen of information on the mail utility is displayed.
NOTE:
There are two major versions of the mail utility. One is UNIX System V and the other is Berkeley based. The Berkeley version is supplied with System V as mailx, although it is possible that it has been moved to the mail name. This book discusses the Berkeley /usr/ucb/Mail version and the System V /bin/mailx version of mail and refers to it as mail/mailx.
LOGGING OUT OF THE SYSTEM
To log out of UNIX you must exit the shell. There are multiple ways of exiting the shell; the most common is pressing Ctrl-D. You may also type exit and press Return or, on some systems, you may type logout and press Return.

Posted by MALIK

Labels: code, free, linux, open source, operating system, unix

UNIX and LINUX part 5


TEXT EDITING AND DISPLAYING
UNIX provides multiple ways to enter text into files. The most common way is to use one of the editors. The editors are ed, ex, and vi. The ed editor is the most basic editor. It is a line editor. A line editor does not display the text on the screen while you are editing. You have to display the text, then perform editing functions on a line-by-line basis.
The ex editor is an enhanced version of the ed editor. It provides much better substitution and addressing capabilities. But it is still a line editor.
The vi editor is a visual editor built on top of the ex line editor. Thus vi has the power of visually displaying the text you are working on while also having a powerful line editor to perform substitutions and other necessary functions.
The following steps show you how to create a file using the vi screen editor. It is advisable to learn the ex and vi editors because of there power and popularity.
1. Before you begin using vi you must have your environment set properly. First type env and press Return. Notice that a list of variables is displayed on your screen. Look for the TERM= variable in the list. This variable must be set before vi will perform correctly.
C Shell
Type printenv and press Return.
2. To set TERM to a desired terminal type, type TERM=VT100 and press Return. Replace VT100 with the type of terminal you are using.
C Shell
Type set term=vt100 and press Return.
3. Begin editing a file by typing vi file1 and pressing Return. Notice the screen is cleared and tildes (~) are placed along the left side. The filename is placed on the bottom line along with status information. Your screen looks like the following display.
4. To enter text, type i; this puts vi in insert mode. Now type This is a new file created by vi. and press Esc. Notice you entered a line of text and now the cursor is at the end of the line.
5. To duplicate the line, type yy to yank it to a register and type p to put it back on the screen. Notice you now have 2 lines of text that are identical.
6. To move up 1 line type k, to move down 1 line type j, to move right 1 character type l, and to move left 1 character type h.
7. To jump to the beginning of the current line type 0. Notice the cursor moves to the beginning of the line.
8. To jump to the end of the current line type $. Notice the cursor moves to the end of the line. Remain in vi to continue the following steps.
The following steps show you how to interface with ex commands while in vi.
1. Type :ver and press Return to display what version of vi/ex you are using. On some systems you will need to press Return to redisplay the vi screen.
2. Write the file to disk by typing :w and pressing Return. On some systems you will need to press Return again to redisplay the vi screen.
3. To substitute a string throughout the file (global substitute) type :%s/a new/an old/g and press Return. Notice that both lines changed from having the string "a new" to having "an old." The percent sign (%) tells ex to search lines 1 through end-of-file (EOF). The "s" tells ex to perform a substitution. The "/a new/an old/" says to search for "a new" and change it to "an old." The g tells ex to change all occurrences on a line. The default is to change the first occurrence on each line. Press Return.
4. To escape to the shell type :sh and press Return. Notice a shell prompt appears on your terminal; you have been placed in a new subshell. You may execute any normal UNIX command. To return to vi/ex press Ctrl-D and then press Return.
5. To execute a UNIX command without leaving the editor type :!cat % and press Return. The % is expanded by vi into the current buffer name (file1). The command cat file1 is executed and control is returned to vi.
6. To save the file to disk and exit vi type ZZ (capital letters).

Posted by MALIK

Labels: code, free, linux, open source, operating system, unix

UNIX and LINUX part 4


Using Redirection
The ">" symbol redirects standard output to a file.
1. Create a file by typing cat > myfile and pressing Return. Then type in the following text and press Ctrl-D. The ">" symbol informs your shell to redirect output of the cat command to a file, "myfile." The cat command reads from the standard input in this example.
cj> cat > myfile
Name:Address1:Address2:City:State:Zip
Someone:916 Hawk Street::Austin:Texas:78749
Anyone:Eagle Avenue:Suite 100:Dallas:Texas:75218
^D

2. Now type cat myfile and press Return to display the contents of the file.
3. Create a directory by typing mkdir temp and pressing Return. Then type ls and press Return. Notice that temp is now listed in your directory.
cj> mkdir temp
cj> ls
myfile
temp

4. Type ls -l and press Return to produce a long listing of your directory. Notice the temp line starts with a "d" and the myfile line starts with a "-". The "d" signifies a directory. The "-" siginifies a normal file.
5. Now set up a directory structure in your HOME directory for later use. Type mkdir letters bin tmp and press Return. This creates the "letters," "bin," and "tmp" subdirectories in your HOME directory.
Using an editor
There are three popular editors on UNIX that can be used to create files. They are ed, ex, and vi; please refer to the module that describes each of these editors (Module 39, Module 43, and Module 151).
COPYING AND COMBINING FILES
UNIX provides multiple commands to copy files. The following commands are the most commonly used.
1. Copy myfile to phone.db by typing cp myfile phone.db and pressing Return. The cp command does not display information if it was successful.
2. Combine two files using the cat command by typing cat myfile phone.db > myph and pressing Return. A new file called "myph" is created.
3. Display the contents of the myph file by typing cat myph and pressing Return.
RENAMING AND MOVING FILES AND DIRECTORIES
The following command renames files or moves them to another directory.
1. Rename the phone.db file to phone by typing mv phone.db phone and pressing Return. Again no response if mv was successful.
2. Type mv temp db and press Return to rename the temp directory to "db."
3. Type mv phone db and press Return to move the phone file to the db directory.
CHANGING DIRECTORIES
To move around from directory to directory you use the cd command.
1. Type cd and press Return to make sure you are in your HOME directory.
2. Type pwd and press Return to display your present working directory.
cj> pwd
/u1/ts/mylogin

3. Type cd db and press Return to change to the db directory.
4. Type pwd and press Return. Notice you are now in the db directory.
cj> pwd
/u1/ts/mylogin/db

5. Type cd ../bin and press Return to change to the "bin" directory that you created earlier.
6. Again type pwd and press Return to display your present working directory.
cj> pwd
/u1/ts/mylogin/bin

7. Type cd and press Return to change back to your HOME directory.
DELETING FILES AND DIRECTORIES
The following commands remove files or directories.
1. Remove the files myfile and myph by typing rm myfile myph and pressing Return. The rm command does not respond if it was successful.
2. Type ls -x and press Return to see that myfile was removed.
cj> ls -x
bin db letters tmp

3. Type rmdir tmp and press Return to remove the tmp directory.
4. Type ls -x and press Return to display the contents of your directory.
cj> ls -x
bin db letters

OTHER USEFUL COMMANDS
There are many other commands that make life easy on the UNIX System; the more popular ones are included in the following examples.
1. Type cd db and press Return to change directories to db.
2. Type wc phone and press Return to display how many characters, words, and lines are in the file.
cj> wc phone
3 7 131 phone

There are 3 lines, 7 words, and 131 characters in the file.
3. Select the line containing "Austin" from the file by typing grep Austin phone and pressing Return. Notice the line containing "Austin" is displayed on your terminal.
4. Sort the "phone" file by typing sort phone and pressing Return. Notice that the order of the lines are rearranged and displayed on your terminal in alphabetical order.
System V and BSD with System V extensions
5. Cut out the first field of the "phone" file by typing cut -f1 -d: phone and pressing Return. Your screen should look like the following display:
cj> cut -f1 -d: phone
Name
Someone
Anyone

6. Type cd and press Return to return to your HOME directory.

Posted by MALIK

Labels: linux, open source, operating system, unix

UNIX and LINUX part 1


CORRECTING TYPING MISTAKES
The UNIX System reads each individual character and temporarily saves or buffers them until you press Return or Line Feed. It then interprets the entire line and performs the requested operation.
The UNIX System performs full duplex input/output (I/O) with your terminal. This means you can type characters in to UNIX while UNIX is displaying information out to your terminal. This will result in a messy, hard-to-read screen, but the data will flow both directions, and the input flow will be interpreted in the correct sequence. You may also type ahead of the UNIX System's ability to read the characters, referred to as UNIX's read-ahead feature. The number of read-ahead characters you may type is limited but usually it is more than you will ever need (256 to 4096).
Default Correction Keys
The @(^U-csh), #(DEL-csh) and \ characters have special meaning to UNIX. The @(^U-csh) character deletes the current input line and is referred to as the line kill character. The #(DEL-csh) erases the last character and is referred to as the erase or backspace character. Multiple #(DEL-csh) erases back to the beginning of the current line. The \ character escapes the meaning of any special character. Therefore \# prints a # and does not perform a backspace.
Resetting Correction Keys
The @(^U-csh) and #(DEL-csh) keys can easily be reset. The standard reset values are Ctrl-X (while pressing and holding the Ctrl key, press the X key) used in place of @, and Ctrl-H (Backspace) used instead of #. Most csh users (who are usually on BSD systems) do not reset the ^U and DEL keys.
1. Display the current settings that UNIX interprets as special keys on your terminal by typing stty and pressing Return. Notice the erase and kill default settings. Depending on your system administrator, your settings may differ. The output format for stty may differ if you are on a BSD system.
cj> stty
speed 38400 baud; -parity cread
erase = #; kill = @; swtch = ^';
-inpck icrnl -ixon onlcr tab3
echo echoe echok

BSD (Berkeley)
cj> stty everything
2. Redefine the erase and kill characters by typing stty erase "^h" kill "^x" and pressing Return. The "^" (caret) is typed as Shift-6; do not type Ctrl-H. Notice stty does not display a response.
3. Display the new settings by typing stty and pressing Return.
cj> stty
speed 38400 baud; -parity cread
erase = ^h; kill = ^x; swtch = ^';
-inpck icrnl -ixon onlcr tab3
echo echoe echok

4. Type echo Ti#his is a #n example. at your shell prompt and press Return. Use the appropriate erase key (Ctrl-H/Backspace) in place of the # keys. Notice that when you press your Backspace key the cursor moves back one space.
5. Type echo Another eamxpl@echo Another example and press Return. Use the appropriate line kill key (Ctrl-X) in place of the @ key. Notice that when you press your kill key the cursor jumps to the beginning of the next line; the old line is ignored and a new line of input is read.
BSD (Berkeley)
The new BSD device driver will erase the current line and move your cursor to the beginning of the current line.
6. Type cat/etc/group and press Return. Be ready to immediately press Ctrl-S to stop the output. The Ctrl-S does not appear on your terminal. To resume scrolling of the output press Ctrl-Q.
7. If you have I/O problems with your terminal, check the setting with stty and refer to the stty command (Module 126) for valid parameters. Don't hesitate to request help from a knowledgable source about your terminal and the tty device driver. This is usually a difficult part of UNIX to get a handle on.
KNOWING WHICH UNIX YOU ARE USING
To know which type or version of UNIX you are using, use the uname command. Type uname and press Return. If the name of your system is displayed, you are probably on System V UNIX. If the shell returns a message like "uname: command not found," you are probably on a BSD system.
Another check to perform is to type ls/usr/ucb and press Return. If a listing is returned, you are probably on a BSD-type system. If a message like "/usr/ucb not found" is returned, you are probably on a System V system.
These are not guaranteed checks but they are fairly reliable. If both return info then you are on a hybrid SV and BSD system.
KNOWING WHICH SHELL YOU ARE USING
To know which shell you are using, use the ps command.
On System V type ps and press Return.
BSD (Berkeley)
On BSD type ps -u and press Return.
The right-hand column contains the names of the programs currently executing. If one is csh, you are using the C shell; sh is the Bourne shell, and ksh is the Korn shell.
Another alternative is to type echo $0 and press Return. If you are using the sh or ksh, the corresponding string is displayed on your terminal. If you are using the csh, nothing is displayed

Posted by MALIK

Labels: code, command, linux, sistem, unix

A SAMPLE SESSION WITH UNIX USER COMMANDS


DESCRIPTION
This module provides basic information about getting started using UNIX. It then leads you on a "hands-on" tour of the most commonly used UNIX commands. Because this module is intended to get you familiar with UNIX, it does not provide in-depth explanations. If you wish to know more about a command while you are using it, refer to the module for the given command. The third module provides additional information about features of the UNIX operating system.
The following is a brief outline of information contained in this module. The information discussed in the first four sections is usually set by the system administrator when your login account is created.
* Terminal setup
* Communications between UNIX and your terminal
* Logging in to the UNIX System
* Correcting typing mistakes
* Setting/changing your password
* Knowing which version of UNIX you are using
* Knowing which shell you are using
* UNIX environment
* Executing commands
* Common commands
* Text editing with vi/ex
* Communicating with others
* Logging out of the UNIX System
BEFORE YOU START
Before you can begin using the UNIX operating system you must have a login account. You should request the login account from the system administrator. If you do not have a system administrator, you must create a login account yourself. Check your System Administrator's Guide or Reference Manual for instructions on how to do this.
You will also need a terminal connected to your system. There are several ways for terminals to communicate with the UNIX System: via direct wire, modem, or terminal servers. Your system administrator should connect your terminal to the system.
LOGGING IN TO THE UNIX SYSTEM
Once you have a "login:" prompt on your terminal and a login account, you can log in to the UNIX System. Throughout this book we assume /u1/ts/mylogin is your login (HOME) directory. After you log in and know your HOME directory substitute it in place of /u1/ts/mylogin. We also use the "mylogin" login name; you should replace it with your login name.
1. At the login: prompt type mylogin and press Return.
cj login: mylogin

TIP: Make sure your CAPS key is not activated. If you have a LOGIN: prompt in all capital letters, press Ctrl-D and wait for a new login: prompt to appear, then try to log in to the system.
NOTE:
Your login name must contain one lowercase character. If you do not type at least one lowercase character, UNIX assumes your terminal cannot generate lowercase ASCII characters and treats all characters as uppercase for the remainder of your login session.
2. Type iamuser2 and press Return at the passwd: prompt to log in to the system. Be patient! Depending on your system and its load factor, it could take from a few seconds to a few minutes for the system to respond.
cj login: mylogin
passwd:

NOTE:
Your password will not be printed, or "echoed," as you type it. The UNIX System disables the output so nosy people are not able to read your password.
3. If your login was successful, you should see information displayed on your screen. If your login attempt was unsuccessful, your display will resemble the following,
cj login: mylogin
passwd:
Login incorrect.
login:

NOTE:
If, after a couple of attempts, you cannot get logged in, check your login name and password with the ones your system administrator gave you. If you are still unable to gain access into the system, contact your system administrator, he/she likes to hear from frustrated users!
Messages from the system
The following list is a possible sequence of what may appear on your screen once you type the correct password. You may be required to type information to complete the login sequence. This depends on your local system.
* General information about the local UNIX System is displayed on your terminal from the message of the day file (/etc/motd).
* System displays or lists unread news items.
* System displays or informs you of mail you have received.
* You may be requested to set your terminal type.
* System displays various other information the system administrator has set up.
* A prompt from the UNIX shell (command interpreter) appears. The default prompt is a dollar sign ($).

Posted by MALIK

Labels: code, command, linux, sistem, unix

Program interuption

Sometimes we meninterupsi program yangf are dieksekusi.Anda can stop the program with a special code:
. Intr or quit
You may know the key used to generate characters Intr by typing stty-a

xxx, xxx-malix: ~ $ stty-a

38,400 baud speed; rows 24; columns 80; line = 0;

Intr = ^ C; quit = ^ \; erase = ^? kill ^ = U; EOF = ^ D; M-eol = ^? eol2-M ^ =?

swtch-M ^ =? start = ^ Q; stop = ^ S; susp = ^ Z; rprnt = ^ R; werase = ^ W;

lnext = ^ V; flush = ^ O; min = 1; time = 0;

-parenb-parodd cs8 hupcl-cstopb cread-clocal-crtscts

ignbrk-brkint-ignpar-parmrk-inpck-istrip-inlcr-igncr icrnl ixon-ixoff

iuclc-ixany imaxbel iutf8

opost-olcuc-ocrnl onlcr-onocr-onlret-ofill-ofdel nl0 cr0 tab0 bs0 vt0 ff0

isig icanon iexten echo echoe echok-echonl-noflsh-xcase-tostop-echoprt

echoctl echoke


UNIX command base

other than the command of a bult-in for the shell, UNIX provides many useful tools for pemakai.contoh:

the environmental system
Exit: Exit from the shell on the Bourne shell, the Bourne Again shell, and Korn Shell

id: Showing the user name and its identity from pemakaiserta name of the group and the number of group identity

logname: Showing the user name
logout: Exit from the shell in the C sheel and the Bourne Again shell
man: Showing the online documentation from a UNIX command
newgrp: Change the group effective
passwd: To change the password and password
set: Showing variable in the shell user
TTY: display name (port) terminal
uname: Displays the name of the hub system UNIX
Justice: Showing the user that is using the system

command file management

paint: Displays the contents of the file
cp: copy files
find: Finding files on a particular directory
ls: Displays information berkascd
more: Showing the contents of text per screen suaru
mv: Moving a file to another directory or file name change
pg: Showing isiberkas text per screen
rm: Deleting files

the management of the directory

cd: Leaving directory as a directory of work
copy: Copy the entire directory structure (including files and subdirectories)
mkdir: Make a new directory
pwd: Showing namadirektori work
rmdir: Removing directory
mv: change the name of the directory

command to manage access to files

chgrp: Change the group from a file or directory
chmod: Change the permissions of a file or directory
chown: Change the owner of a file or directory

commands associated with the process

Vette: Stopping a process based on the identity of the process
ps: Showing the process - a process that is running
sleep: to delay the execution (the process does not do anything for a few seconds)

commands associated with the screen

banner: Showing writing large
clear: Removing the screen
echo: Showing writing to the screen

the other - other

bc: Tools for calculation melakaukan
cal: Manampilkan calendar
date: Showing the date and time system
gep: Finding files - files that contain the word - a word a certain
lp: Prints file to the printer
mail: Tools for delivering a written message to other users
sort: managing data
vi: Text Editor
WC: Calculating the number of characters, words and lines in a file

command - the command above basic command from UNIX, which will be discussed at the next pos

Posted by MALIK 0 comments

Labels: linux, open source, operating system

Linux part 4

xData BeOS 4.5 with the following advantages and disadvantage.


Platform: PowerPC, Intel
Architecture: 32 bits, Preemptives multitasking, Multithreading, Symmetrical Multiprocessing, network support integrated, optimized for the web.
RAM: 16 MB minimum
Capacity hard disk: at least 150 MB
File system itself: Journaling 64 bit, multithread.
Other file system: FAT 16, FAT 32
Kernel: MACH


Advantages:

1. Optimal for multimedia applications (video editing process or audio).


2. Multithread system is unique in optimizing the two or more processors.


3. Handling file system for 64 bit large.
4. Promising future in the near future because the operating system will get support from hardware manufacturers in Europe, BeOS planned will support the Intel Pentium III and can function as dual-boot able to read and write FAT file system of Windows and DOS.


Cons:


1. The absence of an application office / business leaders appropriate or good.


2. This operating system appears only on the operating system oriented multimedia course.


3. At least for desktop applications at this time.


4. For the current operating system BeOS is not an operating system that is open-source.


2.2.2. OS / 2 Warp: Server Business expensive. Operating system OS / 2 Warp developed by IBM. In version 4 (Merlin), there are important updates with the view that there is far more beautiful and very similar to the Windows'95 and the introduction of language integration. And now in version 5 (Aurora), IBM to make improvements to the general technique, which can be put in front of the Warp for Windows NT. The most important innovation in the
version 5 is "Journaling File System (JFS). More resembles the structure of the database system files. JFS blessing, every change can be canceled and integrity checks as requested by the NTFS system or the other is not necessary. And this is a big advantage for a server, which should always be available 100%, both in the Intranet and Internet. Software is available for private users is relatively small. For business applications already available version of Star Office is appropriate. In the field of application specific, for example, banks or insurance, where security is an important investment for
customers, OS / 2 for profitable investment because able to support the old version.

The main merit of the OS / 2 is a strong architecture. Preemptives multitasking kernel is very stable and can only disaingi by UNIX. Java integration in the system to make Warp server platform connecting this to be a "server for all." This may be the future trend, which connects all the Warp operating system with all platforms in the network ( "any to any").


2.2.2.1. Data OS / 2 Warp Server for E-Business with the following advantages and disadvantage.


Platforms: Intel
Architecture: 32 bits, Preemptives Multi-tasking, Multithreading, Symmetrical Multiprocessing, network support, optimal for the Web, Java, network management, and speech-recognition integrated.
Kernel: monolithic.
RAM: 32 MB minimum
Capacity hard disk: at least 350 MB
File system: the HPFS, Journaling File System (JFS), multithreaded.
Other file system: FAT, with the help of shareware: FAT 32, VFAT, NTFS, ext2fs, HFS.


Advantages:


1. Stable system for corporate networks, servers and communications transactions, which connects multiple platforms.


2. Multithread system that resembles BeOS.


3. The view that much more beautiful than the Windows'95 and the integration of the introduction
language.
4. The server operating system available 100%, both in the Intranet and Internet, owing to help JFS.


5. Profitable for investment because it can support the older version.


Cons:


1. Not many software for personal users, other than Office.


2. Prices are expensive to make the user a weak financial structure reluctant to buy them.

3. Questions stability is not yet compete UNIX.


4. Special use for business, not for personal or among PC users.

Posted by MALIK 2 comments

Labels: code, free, linux, open source, source

Linux part 3

BeOS Operating System: Multimedia Operating System.


Since the first version in 1997, one of the main goals BeOS, is managing the large amount of data that is optimal. This operating system can meet the demands of multimedia applications with the support of multi-processor, 64 bit file system, and multithreading.
BeOs can use and exploit all available processors, either one or 16 processors. Users do not need to upgrade computer with only enough to replace the motherboard or install new porcessor. In the first BeOS developed to BeBox, a computer with 2 PowerPC processor and main memory with a maximum of 256 MB. Although the BeOS including the very first complete BeOs but can not rival operating systems such as Intel and Macintosh. So since version 3, BeOS is available for Macintosh and Power-PC based Intel

Multithreading burden several processors at once.


With multithreading architecture, BeOS optimally utilize the processor. From the file system to display, the operating system for the divided-in threads. Threads are jobs or tasks that can be done separately and not depend on one another. When there are several processors on a PC, then split BeOS threads dynamically to each processor. Example: In the file system, a processor that change some of the files, while the other processor mencopy file

64 bit file system for large files.


Operating systems such as Windows 95/98 work with 32 bit file system that limits the maximum of 4 GB file. The size is adequate to process the audio, where audio 1 hour average confiscate 600 MB of space on an audio CD. With 64 bit file system, a file on the BeOS can reach sizes up to 18 million terabyte or 18 billion GB. In addition, file system also records all done. This means that, after the electricity connection is lost, all he can to restore the data back. When the server operating system requires long hours for it, the BeOS only need a few minutes, because it only re-start downloading a transaction that has not been completed and closing. Action has been completed removed from the protocol. BeOS on the object-oriented (object oriented). For software developers, this means he can return to the object system. Examples are Bapplication, Bwindows
or Bview. A simple program such as Hello World consists of only a few lines of code, where the descendants of these objects can be "inherited" and modified.


Posted by MALIK 0 comments

Labels: free, linux, online, open source, protocol, source

C ++ part 3

CD RENT APPLICATION

/ Asumsi - asumsi :
// 1. Rental hanya mempunyai 10 CD
// 2. Pada state awal, CP01, CP03, CP07 sudah dipinjam
// ************************************************************

#include
#include
#include

int main()
{

// Deklarasi Variable
char inpmenu, inp[4], any;
int st, stat, x, y;
char nama[6] = {' '};

// Dumping Data CD
char cd[10][4] = { {'C','P','0','1'}, {'C','P','0','2'},
{'C','P','0','3'}, {'C','P','0','4'},
{'C','P','0','5'}, {'C','P','0','6'},
{'C','P','0','7'}, {'C','P','0','8'},
{'C','P','0','9'}, {'C','P','1','0'}
};

// Dumping Data Peminjaman
char pinjam[10][10] = {
{'C','P','0','1','H','a','t','m','a'} ,
{'C','P','0','2',' ',' ',' ',' ',' ',' '},
{'C','P','0','3','M','a','y','a','n','g'},
{'C','P','0','4',' ',' ',' ',' ',' ',' '},
{'C','P','0','5',' ',' ',' ',' ',' ',' '},
{'C','P','0','6',' ',' ',' ',' ',' ',' '},
{'C','P','0','7','A','i','n','a'},
{'C','P','0','8',' ',' ',' ',' ',' ',' '},
{'C','P','0','9',' ',' ',' ',' ',' ',' '},
{'C','P','1','0',' ',' ',' ',' ',' ',' '}
};

// Menu Label
menu :

// Clear Screen
system("clear");

// Greeting

cout << "+-----------------------------------+" <<>

// Menu
cout << "Silakan pilih proses yang akan dilakukan" <<>

// Input Menu
cout << "\n>> Pilihan Anda : ";
cin >> inpmenu;
cout <<>

// Greeting
cout << "+-----------------------------------+" <<>> inp;

// Validasi Input - Check Apa CD Tersedia
x = 0; st = 0;
do
{
for (y=0; y<4; st =" 0;" st="="4)">> nama; cout << z =" 0;" stat="1;" x="1;" x="="10)" stat="0;" x="0;" b="0;">

Posted by MALIK 0 comments

Labels: c ++, c#, code, linux, online, open source

Basic Policy Linux part 3

Change the file access permission
Changes in the permissions of a file or directory that has the rights is the root and its owner, then the command to make changes that are sebai following:
chmod [librieragazzi] [+/-] [r / w / x] [-R] directory / file
information:
u user
g group
o, other
+ Gave permission permisinya
- Remove or revoke permits permisinya
R-recursively for a directory
example:
# Ls-l modul_admin
-rw-rw-r - 1 unit of TI-1570 Jun 20 07:43 modul_admin
# Chmod + wx go modul_admin
# Ls-l modul_admin
-rw-rwxrwx 1 unit of TI-1570 Jun 20 07:43 modul_admin
the meaning of the command chmod + wx modul_admin go gave the group permission to
and the other to modify and run a file called modul_admin
Return to revoke the permit was granted to use the following command:
# Chmod go-wx modul_admin
# Ls-l modul_admin
-rw-r - r - 1 unit of TI-1570 Jun 20 07:43 modul_admin
as a note: to change the permission or license directory, the command
used as permission to change the file name of the file only be replaced with
the name of the directory.

3. Change the ownership of files and directories
At the time a file is created so that it is the owner of the file. Owner is that most people have the right to change ownership and permission to access the file.
To change the ownership of a file, the commands used are:
chown [owner]. [group] nama_filenya
in the following examples we will change the ownership of the file modul_admin:
# Ls-l modul_admin
-rw-r - r - 1 unit-IT-IT units in 1570 Jun 20 07:43 modul_admin
# Chown tamu.tamu modul_admin
# Ls-l modul_admin
-rw-r - r - 1 guest guest 1570 Jun 20 07:43 modul_admin

Basically, the command to change the ownership of a directory of the same
with the command to change the ownership of a file. However, for
change the ownership of a directory should be added the option [-R] (recursively)
that means the replacement of the ownership of a directory with
the contents. The following example to change the ownership of a directory:
# Ls-l
total 128
drwxrwxr-x 3 unit-IT-IT unit 4096 Jun 21 06:40 data
we will change the group and owner of the data that is a unit-IT
guests:
# Chown-R tamu.tamu data
# Ls-l
total 128
drwxrwxr-x 3 guest guest 4096 Jun 21 06:40 data
# Ls-l data /
total 8
drwxrwxr-x 2 guest guest 4096 Jun 21 06:40 change
-rw-rw-r - 1 guest guest 1570 Jun 21 06:38 modul_admin

Posted by MALIK 0 comments

Labels: basic, linux

LINUX

INSTALLATION LINUX

Red Hat is a popular Linux distributions (at least in Indonesia). With the convenience features that make Red Hat is replace the windows. On the other hand, many computer users are reluctant to leave the windows of one hundred percent. Clever solutions to this case is to use two operating systems simultaneously, the windows and linux. However, things are not easy (at least the author of several natural time ago) to install Linux in addition to the windows that have been placed with the sweetness in space
hard drives. Problems most occur in the general division of the partition. Although many software-divider partition, say the Partition Magic-the popular, but the author felt it necessary to write this tutorial, as a guide for which you want to switch to Linux.
RedHat 9.0 released on 31 March 2003, the information and complete Documentasi RedHat Linux can be obtained from the official site RedHat, http://www.redhat.com One thing I can leave in, that all screnshot in the tutorial is taken from the author Documentasi official Red Hat (http://www.redhat.com/docs/manuals/linux/). Preparing Installation Some things you should note before starting the installation is:
  • 1. Divider partition software, like Partition Magic, this software you can buy or download on the Internet site. Please look at www.download.com
  • 2. Or change the size of your windows partition with softaware pambagi the partition as partition magic. So that there is one empty partition to get this installation space of 1.8 GB. In general, if you buy a new computer, then there is only one partition on the hard disk, the C: With this condition, does not allow you to install Linux. So resizing the partition C: in the windows with software divider partitions exist.
  • 3. Find out keyboard configuration. Use the keyboard layout you like on the windows. To find out click Start -> Settings -> Control Panel -> Keyboard. Select Properties on the keyboard language tab. Please note keyboardnya layout.

  • 4. Know Mouse configuration; PS / 2, serial or USB, PS / 2 or USB, to see to know mouse with the CPU (port)

  • 5. Large space that has not been used in hard drives. This is useful for a partition plan that will be created.
To see the use chkdsk command in dos prompt.
  • 6. The type and configuration monitor and video card that you have, the amount of memory your video card, titleyour monitor (title = brand):) And the one thing that you should know is the term vertical and horizontal range of your monitor.
  • 7. Also not less important, before the start, back up your important data first, is to maintainpossible loss of data when the division of the partition.
  • 8. Last prepare cemilan, coffee and magazines. This is very useful once while awaiting installation components that take an hour or more.

Posted by MALIK 2 comments

Labels: linux

Basic Policy Linux

BASIC POLICY-LINUX
A. Basic operation

Not the same as in Windows, the operating system Linux are differentiated between the letters and small letters. Like
between Ls will be different with ls. This applies to command the operation, name
file, directory, and variable. Linux also supports the use of the name of the file
long, separated by spaces.

B. The user name and password

Before the user can enter kesistem, must first register or
username and password to make it in a sistem.Username
words to call into the system. (always a sign perbiasakanlah
your username and cultivated his username is a name or word
easy to remember). Sedangkanpassword a keyword convoy
username. Try your password is easy to remember and not the easy entry.
It is recommended to use a combination of letters and numbers, for example,
4ndh1e.

C. Command structure

command in linux, form:
name, the [selection] [arguments]
example:
ls (no options and arguments)
ls-l (use the options that have the command by itself)
ls-l / etc / (have peritah and arguments)
ls man (seek optin ls)

Posted by MALIK 0 comments

Labels: linux

Linux part 2 distro

DEBIAN

(http://www.debian.linux.or.jp/)
Platform: Intel, m68k (Alpha, PowerPC, Sparc, UltraSparc, ARM and the GNU Hurd in the development stage)
Languages: English, with some support for French, German, Spanish, Italian, Japanese, Korean, Polish, Swedish, China.
WWW: http://www.debian.org/
FTP: ftp://ftp.debian.org/debian and mirror sites via anonymous FTP

Debian Linux is the result of the efforts of volunteers to create a Linux distribution with high quality and non-commercial. The advantage of Debian Linux is upgradability, inter-dependence is defined by the package, and the development of the open.
Debian is the only Linux distribution developed jointly and in cooperation by the people through the Internet, in a spirit of Linux operating system and the 'open source'. More than 400 maintainers package to more than 1,500 packages to Debian and Linux. Bug tracking systems that allow advanced users to easily report bugs and security problems quickly associated with the Debian community. Command-line tool, 'apt-get', can be used dynamically to upgrade your system from the Debian archive network wide. Debian Linux distribution that is very dynamic. The release of SNAP-shot release is made every 3 months, ftp archive it

Posted by MALIK 0 comments

Labels: debian, distro, linux, operating system

Older Posts Home

Links

  • ALJAZEERA TV
  • ANTARA
  • Bali`s Blogger
  • BBC
  • BERITANET.COM
  • CHIP ONLINE
  • CNN
  • DETIK.COM
  • E-BOOK
  • Economic
  • Friends
  • Friendster's Blog
  • Habibieafsyah
  • HARVARD UNIVERSITY
  • ILMU KOMPUTER
  • INFO LINUX
  • KICK ANDY
  • LINUX OpenSuse
  • LINUX SLAX
  • Linux Temanggung
  • LINUX UBUNTU
  • LIPUTAN 6 SCTV
  • MASTER BLOGGER
  • METROTV NEWS
  • MUSIC DOWNLOAD
  • My Class
  • Robotic AMIKOM
  • SMA N 3 TEMANGGUNG
  • SMART E-LEARNING
  • SOFTPEDIA
  • STMIK AMIKOM
  • SUPPORTED BLOGGER
  • TIPS TRICKS
  • TRIAL FILM
  • TV ONE ONLINE

Blog Archive

  • ▼ 2009 (38)
    • ▼ 05/31 - 06/07 (1)
      • Java
    • ► 02/15 - 02/22 (1)
    • ► 01/11 - 01/18 (11)
    • ► 01/04 - 01/11 (25)
  • ► 2008 (70)
    • ► 11/30 - 12/07 (22)
    • ► 11/16 - 11/23 (18)
    • ► 11/09 - 11/16 (1)
    • ► 10/26 - 11/02 (5)
    • ► 10/19 - 10/26 (16)
    • ► 10/12 - 10/19 (4)
    • ► 10/05 - 10/12 (4)



$100.00 Anda pasti untung setelah registrasi!






Search Engine Optimization and SEO Tools







Bookmark CO.CC:Free Domain