Today (Saturday) We will make some minor tuning adjustments to MySQL.

You may experience 2 up to 10 seconds "glitch time" when we restart MySQL. We expect to make these adjustments around 1AM Eastern Daylight Saving Time (EDT) US.

Search Results

Search: Posts Made By: jim mcnamara
49
Posted By jim mcnamara
Running find against / (root) is not great idea. ...
Running find against / (root) is not great idea.

Run your code as a non-privleged user.

Try
find / -type f -name '*.sh' -exec grep -l 'vijay@gmail.com' {} \; > ~/mylist
then check the list....
Forum: Shell Programming and Scripting 2 Hours Ago
93
Posted By jim mcnamara
echo junkword | truss iconv -f UTF-8 -t...
echo junkword | truss iconv -f UTF-8 -t ASCII//TRANSLIT 2>&1|grep Err

Every missing file will show up with ENOENT as the last word. Where you get the files you need, I do not know. An AIX...
Forum: Shell Programming and Scripting 4 Hours Ago
93
Posted By jim mcnamara
That looks like you may possibly be running on...
That looks like you may possibly be running on AIX, please give us your UNIX OS and shell.

The error means iconv cannot find the language file it needs to make the conversion. Finding what...
Forum: What is on Your Mind? 1 Day Ago
298
Posted By jim mcnamara
Peasant, Congratulations. You have many...
Peasant,

Congratulations. You have many good posts to your credit. We appreciate your help.

Best,

Jim M
210
Posted By jim mcnamara
Then your example was misleading me. Any time...
Then your example was misleading me. Any time I see complexity like you describe, it makes me wonder about the analysis performed. Should be looked at. But when we get fractional part of it, we...
210
Posted By jim mcnamara
Hmm. Assuming the file looks like your example -...
Hmm. Assuming the file looks like your example -
FWIW you can do this many ways, you may be over thinking your task.
Example:

greek=$(grep -c "[Gg]reek$" infile)
latin=$(grep -c "[Ll]atin$"...
210
Posted By jim mcnamara
Do you need distinct awk functions for every line...
Do you need distinct awk functions for every line of text or just a few functions? Sample input, output would help a lot.

Edit: I don't understand the request either....
207
Posted By jim mcnamara
Your script as originally posted showed a shebang...
Your script as originally posted showed a shebang for ksh.
Here is what I get:

$ cat t.shl
#!/bin/bash

if [ -z "$BASH_VERSION" ]
then
echo hi
else
echo "characters found"
fi
...
207
Posted By jim mcnamara
echo ${#BASH_VERSION} gives the length of a...
echo ${#BASH_VERSION}
gives the length of a variable, i.e., the number of characters, whether numeric or not numeric.

I do not see what is going on.

Try:
#!/bin/bash
echo "bash version =...
237
Posted By jim mcnamara
I am missing something. By default bash...
I am missing something.
By default bash sources a file .bashrc if one exists in the current working for each "new" bash invocation. The same is true for ~.kshrc. Each "new" invocation of ksh...
144
Posted By jim mcnamara
We need to know what UNIX you have and what shell...
We need to know what UNIX you have and what shell you use. The answers would be all over the place without that information. Thanks.
Forum: Programming 1 Week Ago
370
Posted By jim mcnamara
Banging the metal - Some Solaris 10 & 11...
Banging the metal -

Some Solaris 10 & 11 performance and system analysis code runs using perl interfaces - Dtrace for example. Dtrace also runs on Linux, again perl is a major player.
...
Forum: Homework & Coursework Questions 2 Weeks Ago
335
Posted By jim mcnamara
What OS are you on? If linux there is a command...
What OS are you on? If linux there is a command to do this - seq start increment finish

seq 15.1 .1 15.7
15.1
15.2
15.3
15.4
15.5
15.6
15.7
535
Posted By jim mcnamara
Ok, thanks. Try this to see if it is working...
Ok, thanks.

Try this to see if it is working the way you want -- before you try killing processes:

dsh -w server1 "lsof /audit | awk '{print $2}' | while read pid; do; echo $pid ; done"
...
535
Posted By jim mcnamara
I've stayed away because I could not get past the...
I've stayed away because I could not get past the dsh -w
AIX dsh and linux dash (sometimes dsh) do not have a -w option. Per manpages for both. What does that do -- dsh -w ?

So I'm not sure...
365
Posted By jim mcnamara
I'm not sure what you want - it looks like you...
I'm not sure what you want - it looks like you want the default case to open the browser - default is the choice of the user.
Question: the user enters the number 3. The case statement will...
539
Posted By jim mcnamara
Control B in standard ASCII (STX) is decimal 02...
Control B in standard ASCII (STX) is decimal 02 or ^B according to the list of ASCII values. Not a smiley face.
Windows has different keyboard setups from UNIX. In UNIX they are called locales. ...
529
Posted By jim mcnamara
See oracle docs about the WHENEVER SQLERROR...
See oracle docs about the WHENEVER SQLERROR clause
SQL*Plus Command Reference (https://docs.oracle.com/cd/B19306_01/server.102/b14357/ch12052.htm)

When your code hits an error, your code invokes...
96
Posted By jim mcnamara
Vague - best I can do: you want the screen...
Vague - best I can do: you want the screen command, I think.
1,014
Posted By jim mcnamara
You should ALWAYS check user input - consider it...
You should ALWAYS check user input - consider it toxic if that helps.

If you use linux the -empty test works for what you want - you do not mention your system or shell
i.e.,

# check if it is...
98
Posted By jim mcnamara
I am guessing this post really belongs in another...
I am guessing this post really belongs in another thread. Somewhere. Anybody know? We can move into its proper home
1,058
Posted By jim mcnamara
Using awk - $ awk '/^app/ {pre=$0; next} ...
Using awk -

$ awk '/^app/ {pre=$0; next}
length($0) {print pre " " $0 } ' filename > newfile

$ cat newfile
applianceName1 1.0 123 some
applianceName1 5.3 456 random
applianceName1 3.5...
818
Posted By jim mcnamara
$NF is the last column in any record read from a...
$NF is the last column in any record read from a file. It is an awk built-in variable. There are several of them. Since you want the last column changed you need to replace the / character with...
879
Posted By jim mcnamara
This works for me: a=$(echo 'hi there:' && awk...
This works for me:
a=$(echo 'hi there:' && awk '{printf " %s:\n ip: %s\n", $2, $1 }' host2.txt)
echo "$a" > yaml_file

Note I added 'hi there', should be something else.
If you run a...
Forum: Programming 07-04-2019
1,309
Posted By jim mcnamara
What you want is the equivalent of the which...
What you want is the equivalent of the which command - it uses the PATH variable to decide where to look.

#!/bin/bash
# usage: ./check executable_name_goes_here
#
export...
Showing results 1 to 25 of 500

 

Featured Tech Videos