Sponsored Content
Full Discussion: Back Command
Top Forums UNIX for Dummies Questions & Answers Back Command Post 50473 by google on Sunday 25th of April 2004 09:38:00 AM
Old 04-25-2004
Pick up a book called "Unix In A Nutshell" by O'Reilly. Great command syntax book to have. Until then, a few more useful commands:

Code:
Print (current) working directory name
pwd
Pathname seperator
/
Working directory's pathname
.
Parent directory's pathname	
..
List working directory's contents
ls
List working directory's contents using long list file information
ls -l
List working directory's contents one page at a time
(push space or next page)
ls -1 | more ("less" for linux systems)
List directory contents at pathname
ls pathname
Change Directory: Changing the current directory to your home
directory
cd
Change Directory: Change directory to pathname
cd pathname
Permission: Set access permissions for a file or directory at pathname
chmod permissions pathname
Copy file "original" to file "duplicate"
cp original duplicate
Move/rename file old to file new
mv old new
Delete file
rm filename
Remove an empty directory at pathname
rmdir pathname
Find location of files or folders, searching from the top of the
directory tree, using rules (see man find)
find top rules


Last edited by google; 04-25-2004 at 10:45 AM..
 

8 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Need to go back 1 day using the date command

I am trying to write a shell script to look at log files with dates in the file name. Now I know how to use the expr command to subtract 1 day from the other, which is simple when the dates are from the 2nd to the 31st of each month. But the problem I have is when the date turns to the 1st... (4 Replies)
Discussion started by: cfoxwell
4 Replies

2. UNIX for Dummies Questions & Answers

sed command for using with back slashes

hi all, im trying to use a sed command to remove all occurenes of \p\g what i used so far is : sed 's!\p\g!!g' file but this doesnt work ? Any ideas, thanks for helping. (2 Replies)
Discussion started by: seaten
2 Replies

3. AIX

back to back printing in UNIX

Hi , Can you suggest me how to back to back printing in UNIX? Is there any way? Kindly advise. Regards Vijaya Amirtha Raj (3 Replies)
Discussion started by: amirthraj_12
3 Replies

4. IP Networking

Back-to-Back Connection using HBAs

Hi every body, Is it possible to connect two servers Back-to-Back (Point-to-Point) using HBA adapters & using Fiber. Note it is direct connection & there is no switches between the servers. I'm concern about using HBA adapters, it is possible or not. Thanks in advance. :) (3 Replies)
Discussion started by: aldowsary
3 Replies

5. UNIX for Dummies Questions & Answers

back up command and syntax

what is the back up command to take back up files and syntax (1 Reply)
Discussion started by: sunilamarnadh
1 Replies

6. What is on Your Mind?

I'm back

Hi all, I used to post here years ago, and was a moderator, my old username: zazzybob. Anyway, after a few years away focusing on my career, I'm back and keener than ever to get involved in the unix.com community again. I'm looking forward to getting back into the swing of things, helping... (11 Replies)
Discussion started by: tokiwinter
11 Replies

7. Shell Programming and Scripting

Sql command inside shell script runs without giving anything back as outout

#!/bin/sh # This script returns the number of rows updated from a function echo "The execution is starting ....." sqlplus -silent $UP <<EOF set serveroutput on set echo off set pagesize 0 VAR no_rows_updated NUMBER; EXEC :no_rows_updated :=0; DECLARE CURSOR c_update is SELECT * FROM... (4 Replies)
Discussion started by: LoneRanger
4 Replies

8. Shell Programming and Scripting

sed - use back reference in 2nd command

I have data that looks like this: <Country code="US"><tag>adsf</tag><tag>bdfs</tag></Country><Country code="CA"><tag>asdf</tag><tag>bsdf</tag></Country> I want to grab the country code save it, then drop each new "<..." onto a new line with the country code added to the beginning of each So,... (9 Replies)
Discussion started by: JenniferAmon
9 Replies
chdir(2)							System Calls Manual							  chdir(2)

Name
       chdir - change working directory

Syntax
       chdir(path)
       char *path;

Description
       The  path  is  the  pathname  of  a directory.  The system call causes this directory to become the current working directory, which is the
       starting point for pathnames that do not begin at the root directory (/).

       For a directory to become the current directory, the process must have execute (search) access to the directory.

Return Values
       Upon successful completion, a value of 0 is returned.  Otherwise, a value of -1 is returned and errno is set to indicate the error.

Environment
       Differs from the System V definition in that ELOOP is a possible error condition.

Diagnostics
       The system call fails and the current working directory is unchanged under the following conditions:

       [ENOTDIR]      A component of the pathname is not a directory.

       [ENAMETOOLONG] A component of a pathname exceeds 255 characters, or an entire path name exceeds 1023 characters.

       [ENOENT]       The named directory does not exist or the path points to an empty string and  the  environment  defined  is  POSIX  or  SYS-
		      TEM_FIVE.

       [EACCES]       Search permission is denied for any component of the path name.

       [EFAULT]       The path points outside the process's allocated address space.

       [ELOOP]	      Too many symbolic links were encountered in translating the pathname.

       [EIO]	      An I/O error occurred while reading from or writing to the file system.

       [ESTALE]       The  file  handle  given in the argument was invalid.  The file referred to by that file handle no longer exists or has been
		      revoked.

       [ETIMEDOUT]    A connect request or remote file operation failed because the connected party did not properly respond  after  a	period	of
		      time that is dependent on the communications protocol.

See Also
       chroot(2)

																	  chdir(2)
All times are GMT -4. The time now is 09:38 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy