LINUX.IE, website of the Irish Linux Users' Group
Tux rules!

   
Home
New Users
Articles
Download
Projects
Community
Vendors

  Print Version
Email to...
 
Archives:


planetILUG

Recent News

News Archive


Join the
ILUG
on FaceBook


Join the
ILUG
on LinkedIn


Join the
ILUG SETI
Group



















 
 :: Mailing Lists

[CLUG] I'm locked!

[CLUG] I'm locked!

Jerry Walsh jerry at nitroweb.net
Tue Mar 13 13:10:40 GMT 2001


"hey, Mr. Bob, I really                                          
want to use that file you have locked.  Please freeup that file and report                                          
accordingly to User/Parent process that you had a request for that file, but                                        
dont try to bomb out..." => killall -9 building bob_himself his_digger bricks etc. etc.

;)

I'm bored.

Jerry.


somebody called Baldwin_James at emc.com wrote:
> Cheers Paul for the info..
> 
> To explain, (with return comments) see below :)
> 
> >>>>> "BJ" == Baldwin James <Baldwin_James at emc.com> writes:
> 
>     BJ> How do ya find out the PID's & UID's (and/or maybe parent
>     BJ> PID's of Child processes) which are locking a file?
> 
> lsof can tell which processes have a file open.  I think it will also
> indicate if the file is locked.  Given the PID gleaned from lsof, you
> can then use ps to get any other needed information.
> 
>     BJ> How could you unlock the file from them without killing their
>     BJ> process?
> 
> Paul asked: > Why would you want to do that?  If you did do that, the
> calling
> Paul asked: > process with the lock wouldn't know about it, so it would
> carry on
> Paul asked: > doing whatever it is doing to the locked region.
> 
> If a process is hung which has a log file locked for exclusive access, and
> you wanna examine that log file without destroying the PID and then return
> the lock back to the PID.  I am basically trying to be as non-intrusive as
> possible (this instance would be on a remote system).
> 
>     BJ> How could you inform the user or push a std. file-handling
>     BJ> command to instruct the process to release the file?
> 
> Paul asked: > I'm not sure what you mean by this, to be honest.
> 
> Lets say, you are able to identify that Bob the Builder, (e.g. UID#505) has
> Frags.log open and you want to use (Read/Write)that file.  You need to
> inform Bob to release/close that file so you can get it.  How can you inform
> Bob about this?  
> 
> If Bob the builder is a process rather than a user, then is it possible for
> some type of Unix/Linux directive to basically say "hey, Mr. Bob, I really
> want to use that file you have locked.  Please freeup that file and report
> accordingly to User/Parent process that you had a request for that file, but
> dont try to bomb out..."
> (I would think the above request would be app-dependent unless coders follow
> some type of practice like this????)
> 
> 
> Cheers Paul,
> James.
> 
> 
> 
> -- 
> "Pity has no place at my table."
>       -- Dr Hannibal Lecter
> 
> _______________________________________________
> Cork maillist  -  Cork at linux.ie
> http://www.linux.ie/mailman/listinfo/cork
> 
> _______________________________________________
> Cork maillist  -  Cork at linux.ie
> http://www.linux.ie/mailman/listinfo/cork

-- 
Jerry Walsh                            jerry at nitroweb.ie
NitroWeb Computing Ltd.                Fax +353 21 4776209
Crossmahon, Bandon,                    Tel  +353 21 4775540
Cork Ireland.                          http://www.nitroweb.ie/ 

------------------------------------------------------------------
Legal Notice
------------------------------------------------------------------
The information in this email is confidential and may be legally 
privileged. It is intended solely for the addressee. Access to 
this email by anyone else is unauthorized. If you are not the 
intended recipient, any disclosure, copying, distribution or any 
action taken or omitted to be taken in reliance on it, is prohibited
and may be unlawful. When addressed to our clients any opinions or
advice contained in this email are subject to the NitroWeb terms
and conditions.
------------------------------------------------------------------





More information about the Cork mailing list
Read this without the formatting.
                                                                                                    

 

Hosted by HEAnet


Maintained by the ILUG website team. The aim of Linux.ie is to support and help commercial and private users of Linux in Ireland. You can display ILUG news in your own webpages, read backend information to find out how. Networking services kindly provided by HEAnet, server kindly donated by Dell. Linux is a trademark of Linus Torvalds, used with permission. No penguins were harmed in the production or maintenance of this highly praised website. Looking for the Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!
RSS Version
Powered by Dell