Problem with deleting .dmp file


 
Thread Tools Search this Thread
Special Forums UNIX Desktop Questions & Answers Problem with deleting .dmp file
# 1  
Old 07-17-2012
Problem with deleting .dmp file

Hi, everybody!
I have a big problem. I don't understand Unix, but I work as a system administrator, and sometimes I make some data exports and I have to delete old .dmp files, but today I had a mistake, I wrote rm * 909*
This is a part of my folder contents in unix before deleting
Code:
drwxrwxr-x 2 oracle dba 1024 Sep 15 10:49 .
drwxr-xrwx 6 oracle dba 1024 Dec 6 2010 ..
-rw-r--r-- 1 oracle dba 1005568000 Sep 12 08:38 XX_20110909.dmp
-rw-r--r-- 1 oracle dba 81120256 Sep 12 08:42 YY_20110909.dmp
-rw-r--r-- 1 oracle dba 580651008 Sep 14 08:32 XX_20110914.dmp
-rw-r--r-- 1 oracle dba 580096000 Sep 15 10:51 YY_20110915.dmp
-rw------- 1 oracle dba 522096 Nov 5 2010 core
oracle@ZZ-dbux:/oracle/exp/myfolder$ rm * 909*
rm: 909* non-existent

Then I wrote ll command and I found only these rows
Code:
drwxrwxr-x 2 oracle dba 1024 Sep 15 10:49 .
drwxr-xrwx 6 oracle dba 1024 Dec 6 2010 ..

I have no idea what is the role of the last row. What do it?

Vietnam Software Outsourcing

Last edited by susan12; 07-23-2012 at 01:23 PM.. Reason: please use code tags
# 2  
Old 07-17-2012
. is a special folder meaning 'current directory'.
.. is a special folder meaning 'previous directory'.

They are hardcoded, and exist everywhere it makes sense for them to do so (.. can't exist in /, of course.)
This User Gave Thanks to Corona688 For This Post:
# 3  
Old 07-17-2012
@corona:
Quote:
(.. can't exist in /, of course.)
.. is present under root, however .. under root points to the current directory itself. Any specific reason why .. is displayed under root? ( I saw this behavior in RedHat Linux and AIX).
# 4  
Old 07-17-2012
Quote:
Originally Posted by susan12
Hi, everybody!
I have a big problem. I don't understand Unix, but I work as a system administrator, and sometimes I make some data exports and I have to delete old .dmp files, but today I had a mistake, I wrote rm * 909*
This is a part of my folder contents in unix before deleting
drwxrwxr-x 2 oracle dba 1024 Sep 15 10:49 .
drwxr-xrwx 6 oracle dba 1024 Dec 6 2010 ..
-rw-r--r-- 1 oracle dba 1005568000 Sep 12 08:38 XX_20110909.dmp
-rw-r--r-- 1 oracle dba 81120256 Sep 12 08:42 YY_20110909.dmp
-rw-r--r-- 1 oracle dba 580651008 Sep 14 08:32 XX_20110914.dmp
-rw-r--r-- 1 oracle dba 580096000 Sep 15 10:51 YY_20110915.dmp
-rw------- 1 oracle dba 522096 Nov 5 2010 core
oracle@ZZ-dbux:/oracle/exp/myfolder$ rm * 909*
rm: 909* non-existent

Then I wrote ll command and I found only these rows
drwxrwxr-x 2 oracle dba 1024 Sep 15 10:49 .
drwxr-xrwx 6 oracle dba 1024 Dec 6 2010 ..

I have no idea what is the role of the last row. What do it?
You have deleted all the files in the current directory.
Quote:
rm * 909*
works like this
Quote:
rm *
which deleted all files from current dir and then
Quote:
rm 909*
which didn't found any file in the directory so u got an error message.

Quote:
drwxrwxr-x 2 oracle dba 1024 Sep 15 10:49 .
drwxr-xrwx 6 oracle dba 1024 Dec 6 2010 ..
are the links to present directory (.) and the parent directory (..) which will be available in each and all directories in unix.

Cheers,
Sudeep
# 5  
Old 07-17-2012
Advice:
Until you get used to the commands, use rm -i at the command line and try to match as much of the filename as possible.
The rm -i will prompt you to ask whether you want to delete the each file.

Code:
rm -i *909.dmp

The fact that you accidentally deleted all files in the directory is explained by @sudeep.id above.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

reg problem deleting file

hi, 1. When i am deleting file in the linux machine i am getting below error message. rm text.fil rm: remove regular file `text.fil'? y rm: cannot remove `text.fil': Read-only file system From su also i tried i am getting same error message. 2. Some times the file permissions and user name... (1 Reply)
Discussion started by: coconut.ramu
1 Replies

2. Shell Programming and Scripting

Problem in deleting lines from the file

Hi All I am not able to delete few line from long file. I have a big file which is of 53998 B in size i want to delete lines starting from 32768 to 53998 and collect remaining file in new file. It is giving exception sed: command garbled: 32768,$countd Please find the sample script... (2 Replies)
Discussion started by: rajeshorpu
2 Replies

3. UNIX for Advanced & Expert Users

problem with deleting a file

hi friends, i need to delete a file named "-vyxx-.0.sdct.txt" i'm unable to use "rm -vyxx-.0.sdct.txt" jus give me your suggesstions thanks in advance (5 Replies)
Discussion started by: rprajendran
5 Replies

4. UNIX for Dummies Questions & Answers

problem while deleting a file

Hi , In a particular path the below mentioned three files has been created. -rw-r--r-- 1 edwprod edw 0 Jun 5 00:06 -f%*lock.clock -rw-r--r-- 1 edwprod edw 151 Jun 5 00:06 -f.log -rw-r--r-- 1 edwprod edw 4 Jun 5 00:06 -f%conn_err.out ... (5 Replies)
Discussion started by: anupam_jash
5 Replies

5. UNIX for Dummies Questions & Answers

problem in deleting a file

Hello: I made this mistake on my tru64 machine, I renamed a file from: binary.errlog to binary.errlog(B3) now when im tryign to move or delete the file Im getting: # rm binary.errlog(B3) ksh: syntax error: `(' unexpected 4# mv binary.errlog(B3) log ksh: syntax error: `(' unexpected ... (3 Replies)
Discussion started by: aladdin
3 Replies

6. UNIX for Dummies Questions & Answers

Problem while Deleting file

All, I am trying to delete a user created file from specified folder. This folder is using for my Team member (i.e, Public folder). For example, $ ls -l total 1336 -rw-rw-r-- 1 g_btha customer 2655 Dec 06 12:35 A_COL_1001 While deleting/moving this file I am getting the following... (3 Replies)
Discussion started by: nvkuriseti
3 Replies

7. UNIX for Dummies Questions & Answers

Problem deleting file with special character

I'm having problems deleting a file with a special character and I'm hoping that somebody here can help. The file "-osample1.c" will not remove from my directory. Here is an example of what happens. Any ideas would be appreciated. > ls *sample1* ls: illegal option -- . usage: ls... (2 Replies)
Discussion started by: hart1165
2 Replies

8. Linux

Dmp

hi, anyone know how to enable dynamic mutipathing under redhat AS in a SAN-enviroment? thx a lot (1 Reply)
Discussion started by: pressy
1 Replies

9. Programming

problem deleting date-time stamped file in a directory

I have a number of files of the format filename.xfr_mmddyy_%H%M%S which i get in a specified directory daily. Now i want to search in the specified directory & delete the files which are more than 2 days old .So I use a command find $DIR/backup/* -ctime +2 -exec rm -f {} \; But after executing... (1 Reply)
Discussion started by: dharmesht
1 Replies

10. Solaris

exporting a dmp file (oracle)from unix

i want to export a database (full schema) so that I can import the database to a windows 2000 server. The database is sitting on a unix-sun solaris box ver 8.. What are the commands... I am a bit rusty at unix at the moment! Cheers E (4 Replies)
Discussion started by: etravels
4 Replies
Login or Register to Ask a Question