The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
If doc file exist remove handband2 Shell Programming and Scripting 2 02-11-2009 07:32 PM
If file not exist create a new one din_annauniv Shell Programming and Scripting 3 05-28-2008 08:30 AM
trying to cope with awk difficulties amatuer_lee_3 Shell Programming and Scripting 8 05-11-2008 05:46 PM
Have a shell script check for a file to exist before processing another file heprox Shell Programming and Scripting 3 11-14-2006 03:26 AM
how to check if the file exist or not? gusla UNIX for Dummies Questions & Answers 3 03-27-2002 10:56 PM

 
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1 (permalink)  
Old 02-24-2009
qyxiell qyxiell is offline
Registered User
  
 

Join Date: Dec 2001
Location: Japan
Posts: 3
Question cope exist file prioritie

Hello

I want to make new file which have the same priorities of specified exist file, by super user,
and the file is no contents.

To explain it with example:

exist file:
ls -l old.sql
-rw-r--r-- 1 oracle oinstall 33 Feb 24 16:09 old.sql

if I copy and clean it.
cp -p old.sql new.sql && cat /dev/null > new.sql

ls -l new.sql
-rw-r--r-- 1 oracle oinstall 0 Feb 24 16:20 new.sql

but if the old.sql file is large the operation would be very bad in performance.

can it be finished by one command with good performance ?

thanks in advance.
 

Bookmarks

Tags
cope exist file priorities, unresolved, unresolved for weeks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 09:09 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0