LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This 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


Reply
  Search this Thread
Old 05-13-2009, 10:46 AM   #1
patcheezy
LQ Newbie
 
Registered: May 2009
Posts: 7

Rep: Reputation: 0
Unhappy mkdir : cannot create directory : no such file or directory


uname -a

2.6.18-53.el5 #1 SMP Wed Oct 10 16:34:19 EDT 2007 x86_64 x86_64 x86_64 GNU/Linux

trying to create a directory. Getting the following error.

mkdir : cannot create directory '/u07/oradata/AMPUAT' : no such file or directory

any ideas? Which log could I look at for this type of error? Thanks in advance.
 
Old 05-13-2009, 10:48 AM   #2
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,529

Rep: Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899
Quote:
mkdir : cannot create directory '/u07/oradata/AMPUAT' : no such file or directory
does
Code:
/u07/oradata/
exist ?
 
Old 05-13-2009, 10:49 AM   #3
forrestt
Senior Member
 
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99
The parent directory /u07 or /u07/oradata doesn't exist. Try using the -p option of mkdir to make parents as needed:
Code:
mkdir -p /u07/oradata/AMPUAT
HTH

Forrest
 
Old 05-13-2009, 10:57 AM   #4
patcheezy
LQ Newbie
 
Registered: May 2009
Posts: 7

Original Poster
Rep: Reputation: 0
Do i have to use -p? I remember on on other server not using -p and it worked. Could it be becuase of the version. Thanks for the info.
 
Old 05-13-2009, 10:59 AM   #5
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,529

Rep: Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899
Quote:
Do i have to use -p? I remember on on other server not using -p and it worked. Could it be becuase of the version. Thanks for the info.
because
/u07 and /u07/oradata
already exist on the other server
 
Old 05-13-2009, 11:02 AM   #6
forrestt
Senior Member
 
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99
You don't need the -p if the directory /u07/oradata already exists. However, if it does not exist, and you don't use the -p option, you will get the error you are seeing because the "file or directory" /u07/oradata does not exist. If you use the -p option and the parent directory isn't there, it won't complain, but instead make the parent directory and then make the directory. If the parent directory IS there, it will just make the directory. If you didn't need the -p option on the other server, then I would guess that on the other server /u07/oradata already existed when you ran the command to make /u07/oradata/AMPUAT.

HTH

Forrest
 
Old 05-13-2009, 11:26 AM   #7
patcheezy
LQ Newbie
 
Registered: May 2009
Posts: 7

Original Poster
Rep: Reputation: 0
Cool

thanks for your help
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Trying to make a directory with mkdir using the date command. Altheastronut Linux - General 5 06-09-2009 12:14 PM
samba config: how to allow sub directory and file create pellicle Linux - Networking 1 03-16-2009 10:00 AM
"cannot create directory: ...no such file or directory" fatblueduck Linux - General 7 06-04-2005 10:08 AM
mkdir: cannot create directory `test': Read-only file system punt Linux - General 2 04-16-2005 09:58 PM
"mkdir: cannot create directory `foo': Read-only file system" on FAT32 maddes Linux - Hardware 1 11-26-2003 06:19 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:41 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration