Not a sign of the word AWK anywhere I'm afraid but if I have understood the op's question this would do it ...
for _FILE in `cat file_1`; do if (fgrep -epattern1 -epattern2 $_FILE) then perl -pi.orig -e 's/pattrn3/ChangedIt/' $_FILE; fi ; done
Assuming the OP was wanting to:
1) Go through...
Firstly it would help to know what the file is, where it came from and how you are calling it?
Is it the correct version for your OS 32bit or 64bit?
Lets see the actual output from when you try and run it we may recognise the problem.
As Sam says above use strace to identify exactly what its...
In answer to your question Dan, I'm sure it is possible to use expect however its really easy to set up shared key across your list of servers
On your "host server" (the one that you want to run the distributed commands from) create your key's with:
$ ssh-keygen -t dsa
Accept the defaults and...
Some simple for loop will be what I use like .....
build a server list file:
Contents of serverlist.txt
------------------
server1
server2
server3
server4
~
~
server19
server20
-------------------
Then create a 2 (4) line script like:
#Script to cycle through servers and provide output...
...opps.txt: No such file or directory
Now lets list the files ending in .txt with their inode number (inum) ......
HP-650-Notebook-PC:~$ ls -irthl *.txt
6825593 -rwxrwxr-x 1 fred fred 2.4K Aug 18 08:58 domains.txt
6825592 -rw-rw-r-- 1 fred fred 2.8K Aug 18 09:35 domains_new.txt
6827069...
I suggest that you attach a PC to the ALOM port and login to the console and revert your changes
If that is a problem (no display from the console) then drop back to the ALOM prompt #. and set INPUT/OUTPUT parameters again ..... (with the "set" command) .....
INPUT/OUTPUT...
Apparently it's a limitation of Solaris < 10, and the advice is to shrink your putty/terminal window size so that its not so wide.
I've never had that error myself but if I stretch my PuTTY window too wide I do loose my typed command as it restricts the displayed characters ;(
Maybe take a...
One thing to just watch for is the dross (disconnected) ssh Fallback sessions (processes) left on the calling host machine after you have sent a ssh or scp command in a loop.
I see this often on Solaris machines (not sure if your Linux will behave the same) but it's easy to clean up just ps...
OK so one way is to write a script that calls a set of functions (these functions will have your commands scripted and you call whatever function you want or all one by one)....
OK so Monaco GP started so I have to go .... though this is not tested I hope it will jog your memory and get you...
Why reinvent the wheel ...checkout rsync.
Unless as suggested this is a training project then yes its will be a great project and quite simple to do with basic (default) Unix tools, but you have to take the lead on starting your scripting.
What I find is the best way to start is with a piece...
Hi, You have not said what OS (platform) you are running or what version of Apache or even the changes to the values of all your Apache parameters?
It's difficult to comment without the full detail of your configuration and OS.
However, I suspect that you will not see any logging (unless you...
Hi you will probably find that TOP is not an Oracle (Solaris) default tool and you should probably look at "prstat" which is similar and just as useful.
However, you can find out what version of top is installed on your Solaris machine with
$ top -v
Or identify the package installed that...
Strange as this works for me ....
-bash-3.00$ cat testperl.pl
#!/bin/perl
system("/bin/touch fredtest.tat");
system("/bin/chmod 4777 fredtest.tat");
-bash-3.00$
-bash-3.00$ perl ./testperl.pl
-bash-3.00$ ls -alrth
total 10
drwxr-xr-x 40 fred other 2.5K May 12 11:16 ..
-rw-r--r--...
You don't say what errors you are getting that may help, but are you sure it's not the "test [ -f ]" and the "EOF" that's causing your problem?
I'd put these type of changes in a "post Jumpstart" script myself ...
Sorry otherwise no idea!
Laurie.
Well you can boot from CDRom and mount the disk and fsck and or boot CDRom and reset the root password and fsck ....
If it helps here is a basic root recovery process ....
Load the Solaris cdrom
Take the machine down to the PROM level -
# init 0 (or halt)
When it comes down to the OK...
Ok sorry I probably misread your post .. so you are listening on https, so have you put the RewriteRule in your ssl port 443 area of the apache config or just in the default port 80 section?
ok guessing here as I have no test server to try but I think you still need RewriteCond in there...
We do it this way ....
RewriteEngine on
RewriteCond %{REQUEST_URI} ^http://([^:]*):([^/]*)/(.*)
RewriteRule ^(.*)$ https://%1:%2/%3 [P]
In our case our proxy server reads in the http:// url and rewrites it to the same url as https://
IHTH
Laurie.
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.