I've got to accomplish a very high number of workstation upgrades in a very short amount of time. There will be approximately 2300 machines replaced. Additionally, I won't have access to the old machines for long so I need to make sure I have a good backup of the old machines' drives. We do not...
Had a weird thing happen the other day. I had a new workstation I had just finished loading the new company standard image onto to test it. I was logged in as the local admin. I got pulled away on another job so I locked the workstation and left. When I came back I could not unlock it. I am...
Bah I really need an edit button. While I've been playing with this I have a couple versions open and I had changed the $File var to $DefaultFile which was one I hardcoded to do some testing. Please just read $DefaultFile as if it were $File.
Changed the open line to closely match kevins suggestion. Its now:
[code]
unless (open FILE,$LogPath."/".$DefaultFile) {$Check = 1; $ErrVar=$!};
[\code]
Made no difference that I can see.
Thanks for the input everyone. Kevin you were right on about the quotes. I removed them and the file would open with the small 10 liner script. However, when I modified that on my full script and ran it, it still fails :(
In the full script the filename is not hardcoded but rather pulled...
Thats a great Idea. I created a new file with just the open piece in it and hardcoded it to check a single log file that has the problem. I stuck them both into a new folder and it still generates the error!
Heres the code:
$TestFile = "./kernlr.audit2.log";
open (FILE,"'$TestFile'") or...
I should also have added that right before running the script, I have manually opened several of the files that cause the error with VI. copying and pasting the path and file name exactly the way perl shows it in the error output and I have no trouble opening any of the files I've tested.
Hey Trojan,
Thanks for the response. I certainly agree with you in general and in fact, I really hope it is something simple like that that I've over looked but we can rule out the files still being created. The script actually never tries to access them from the samba share, partly to prevent...
Hi everyone,
I've been wracking my brain on this problem so any help is greatly appreciated.
The problem I am having is regarding reading in a text file for parsing. I have created a script to open and parse several thousand log files. Of those thousands roughly 90 percent will open and...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.