01-08-2008
Quote:
Originally Posted by
Perderabo
A file will no link to a directory will be removed upon the last close.
Is that why I could not see the listener.log.old.gz file when I logged in to check?
If it is removed, then why isn't the space freed?
Thanks for the info btw.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hello
when I try to run rm on multiple files I have problem to delete files with space.
I have this command :
find . -name "*.cmd" | xargs \rm -f
it doing the work fine but when it comes across files with spaces like : "my foo file.cmd"
it refuse to delete it
why? (1 Reply)
Discussion started by: umen
1 Replies
2. UNIX for Dummies Questions & Answers
Hi,
I have a file containing a list of entries.
Want to do ls on them.
for a in `cat <list.txt>`; do ls $a; done;
Now some entries contain spaces.
How do i incorporate space in $a.
Quoting $a in "" doesn't help.
Thanks (6 Replies)
Discussion started by: vibhor_agarwali
6 Replies
3. UNIX for Dummies Questions & Answers
Hi,
I need help how to renaming multiple file. The original file look like this;
Test Monday.txt
Test Wednesday.txt
Test July.txt
I have more than hundred file in the directory.
How i want to rename all file to a new file name in one time? The new file maybe the same name e.g.... (13 Replies)
Discussion started by: nazri76
13 Replies
4. Solaris
Hi,
I'm running a multi-process software system on a Solaris 8 machine. When I monitor the memory usage, I see that the free memory is dropping rapidly, but I can't detect a process that uses this memory.
I'm using "top" to get the free memory and the memory usage of processes.
Thanks. (3 Replies)
Discussion started by: gewurtz
3 Replies
5. Programming
Actually for a process to run it needs text, stack , heap and data segments. All these find a place in the physical memory.
Out of these 4 only heap does exist after the termination of the process that created it. I want to know the exact reason why this happens. Also why the other process need to... (20 Replies)
Discussion started by: karthiktceit
20 Replies
6. UNIX for Dummies Questions & Answers
So I have three space delimited files. Each have 90 rows and many columns. I want to merge them by columns. I use paste to merge file 1 and file2 or file 3 and it works. But when I try to merge file 2 and file 3 using paste or merge or cat, I cannot merge them by column, instead they are merged by... (11 Replies)
Discussion started by: evelibertine
11 Replies
7. UNIX for Dummies Questions & Answers
Hi
Is there an easy was to list a group of file (*.txt) and report how much disk space they are using in total?
Cheers (2 Replies)
Discussion started by: Grueben
2 Replies
8. Linux
Hi all,
Fedora 17, 64bit
Ubuntu 12.04 desktop 64bit
HD 160G
I installed Ubuntu 12.04 on the HD first taking up the whole disc. Later I added/installed Fedora 17 selecting the "Shrink" option and save the bootloader on /dev/sda1 to make them dualboot. Installation is successful with... (0 Replies)
Discussion started by: satimis
0 Replies
9. HP-UX
Hi,
Could you please provide OS command to find large files in size MB and GB... under specific directory in HP-UX?
Regards,
Maddy (4 Replies)
Discussion started by: Maddy123
4 Replies
10. UNIX for Beginners Questions & Answers
Hello,
# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sr0 11:0 1 1024M 0 rom
sda 8:0 0 38.2G 0 disk
├─sda1 8:1 0 500M 0 part /boot
└─sda2 8:2 ... (2 Replies)
Discussion started by: centosadmin
2 Replies
LEARN ABOUT OPENDARWIN
unlink
UNLINK(2) BSD System Calls Manual UNLINK(2)
NAME
unlink -- remove directory entry
SYNOPSIS
#include <unistd.h>
int
unlink(const char *path);
DESCRIPTION
The unlink() function removes the link named by path from its directory and decrements the link count of the file which was referenced by the
link. If that decrement reduces the link count of the file to zero, and no process has the file open, then all resources associated with the
file are reclaimed. If one or more process have the file open when the last link is removed, the link is removed, but the removal of the
file is delayed until all references to it have been closed.
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.
ERRORS
The unlink() succeeds unless:
[ENOTDIR] A component of the path prefix is not a directory.
[ENAMETOOLONG] A component of a pathname exceeded {NAME_MAX} characters, or an entire path name exceeded {PATH_MAX} characters.
[ENOENT] The named file does not exist.
[EACCES] Search permission is denied for a component of the path prefix.
[EACCES] Write permission is denied on the directory containing the link to be removed.
[ELOOP] Too many symbolic links were encountered in translating the pathname.
[EPERM] The named file is a directory and the effective user ID of the process is not the super-user.
[EPERM] The directory containing the file is marked sticky, and neither the containing directory nor the file to be removed are
owned by the effective user ID.
[EBUSY] The entry to be unlinked is the mount point for a mounted file system.
[EIO] An I/O error occurred while deleting the directory entry or deallocating the inode.
[EROFS] The named file resides on a read-only file system.
[EFAULT] Path points outside the process's allocated address space.
SEE ALSO
close(2), link(2), rmdir(2) symlink(7)
HISTORY
An unlink() function call appeared in Version 6 AT&T UNIX.
4th Berkeley Distribution June 4, 1993 4th Berkeley Distribution