Search Results

Search: Posts Made By: Chubler_XL
138
Posted By Chubler_XL
What is the contents of the script then?
What is the contents of the script then?
49
Posted By Chubler_XL
If they are directories in your filesystem you...
If they are directories in your filesystem you could try:

$ cd /PPC/Cloud_Automation/Applications/APPNAME/Files
$ find . -type d -print
.
./Data Management
./Data Management/Data
./Essbase...
138
Posted By Chubler_XL
A issue I see a lot with cron is that the...
A issue I see a lot with cron is that the environment is not set as it is during a normal login. Particularly the PATH environment variable.

With your particular script I'm guessing that...
78
Posted By Chubler_XL
Using tcsh version 6.22.01, with no matching...
Using tcsh version 6.22.01, with no matching files the script appears to be working correctly:

$ ./odensun
find: No match.
find: No match.
No zip files found.
No tar files found.

I suspect...
78
Posted By Chubler_XL
Have you considered using another shell? See: ...
Have you considered using another shell? See:

Top Ten Reasons not to use the C shell (http://www.grymoire.com/Unix/CshTop10.txt)
Csh problems (http://www.grymoire.com/Unix/Csh.html#uh-0)
Csh...
138
Posted By Chubler_XL
Have you considered inotifywait(1)...
Have you considered inotifywait(1) (https://www.unix.com/man-page/debian/1/inotifywait/) provided by the inotify-tools package on some distributions, this can run your script whenever a file appears...
103
Posted By Chubler_XL
This is working as expected in bash 4.4.12 $...
This is working as expected in bash 4.4.12

$ var="/etc/tomcat/server.xml /etc/tomcat/test/server.xml"
$ var2=( $var )
$ echo ${var2[0]}
/etc/tomcat/server.xml
$ echo ${var2[1]}...
349
Posted By Chubler_XL
Nice procedure nezabudka, but original request...
Nice procedure nezabudka, but original request was selection of item by number or by name:



For a higher level of difficulty how about spaces in the options:

#!/bin/bash
listofitems="fried...
349
Posted By Chubler_XL
How about this using the shell select internal ...
How about this using the shell select internal

listofitems="beans rice carrots radishes rutabaga spinach"
MU=( $listofitems Quit )

while true
do
echo "Please enter the veg you like from"...
297
Posted By Chubler_XL
I have had some success with prompting for the...
I have had some success with prompting for the password (without username) from sudo like this:

$ cat /usr/local/bin/zenity_passphrase
#!/bin/bash
zenity --password --title="sudo password...
788
Posted By Chubler_XL
Do the commands realpath or readlink (with or...
Do the commands realpath or readlink (with or without -f) help here at all?

Or perhaps the Cwd module from perl:
perl -MCwd -e 'print Cwd::realpath($ARGV[0])' /home/user_name
592
Posted By Chubler_XL
Sorry about my delay in gettng back think...
Sorry about my delay in gettng back think timezone differences are involved here. looks like we have some nice solutions coming together in this thread now.

This is the pseudo code I had in mind...
592
Posted By Chubler_XL
I can understand that the specifics of what...
I can understand that the specifics of what particular tool or language require knowledge you may not have.

How about trying to give us some pseudo code for how this file should be processed.
...
592
Posted By Chubler_XL
This forum is not a script writing service. ...
This forum is not a script writing service.

If you have a solution you have worked on that is not complete we can help you, but you must have shown some effort to solve this yourself.
385
Posted By Chubler_XL
Following along from jgt's suggestion you could...
Following along from jgt's suggestion you could try this all in one script:

ps aux | (
# discard first (headings) line
read a

while read a b c rest
do
echo -e...
364
Posted By Chubler_XL
As vbe hinted n=($n+1) is unlikely to be doing...
As vbe hinted n=($n+1) is unlikely to be doing what you think it is.

Consider this equivalent code:#!/bin/bash
echo "Let's Get This Started!"

for((n=1;n<45;n++))
{
echo $n. "/$n"
...
3,711
Posted By Chubler_XL
Say you have four values in variable VALS like...
Say you have four values in variable VALS like this a b c d then you can build an array containing these with a simple set statement.
$ set VALS="a b c d"
$ set master_array = ( $VALS )
$ echo...
304
Posted By Chubler_XL
It will make 1 pass through the filesystem from...
It will make 1 pass through the filesystem from the current directory and print the relative pathname of any files that match a1 or *f3 it encounters.
Forum: What is on Your Mind? 02-20-2020
719
Posted By Chubler_XL
Very cool. I did a lot of mucking around...
Very cool.

I did a lot of mucking around with Simulated Annealing and the Metropolis algorithm while in uni. Using it for tasks like fitting various sized files onto minimum numbers of floppy...
427
Posted By Chubler_XL
This looks like a homework question to me, I...
This looks like a homework question to me, I hope you were told not to try running this program on a production system.
462
Posted By Chubler_XL
A process calls the wait() function and kernel...
A process calls the wait() function and kernel level code checks the status of a child process, it will suspend execution of the calling thread until status information for one of the terminated...
1,612
Posted By Chubler_XL
You could use sed (or similar) to convert your...
You could use sed (or similar) to convert your input syntax to an awk expression eg:

CONDITIONS="(1=CT or 2=US_10) and 3=CT_US_10 and 4="
CONDITIONS=$(echo "$CONDITIONS" |
sed \
-e...
Forum: Linux 02-16-2020
949
Posted By Chubler_XL
What value do you have for swappiness...
What value do you have for swappiness (https://en.wikipedia.org/wiki/Paging#Swappiness):

# cat /proc/sys/vm/swappiness
60


You can try tweaking this back a lower percentage (eg add/change...
1,184
Posted By Chubler_XL
Oops, typo in my earlier reply - thanks...
Oops, typo in my earlier reply - thanks MadeInGermany for picking this up.
1,184
Posted By Chubler_XL
2>&1 is an operator which duplicates file...
2>&1 is an operator which duplicates file descriptors, in this case stderr (2) is duplicated onto stdout (1) (See the Duplicating File Descriptors in the bash manual)

In command1 2>&1 | command2...
Showing results 1 to 25 of 500

 

Featured Tech Videos

All times are GMT -4. The time now is 05:33 PM.
Unix & Linux Forums Content Copyright 1993-2020. All Rights Reserved.
Privacy Policy