Search Results

Search: Posts Made By: musicmancanora
4,927
Posted By musicmancanora
yehhh its going to be on a test machine so if it...
yehhh its going to be on a test machine so if it breaks it breaks but im trying to append LK

to the correct field in the shadow field. How could i do that?
2,072
Posted By musicmancanora
appending LK to the shadow file
Hey guys..

i need to be able to append 'LK' to a password field in the shadow file


I cannot use commands such as usermod chsh i need to directly be able to manupilate the files through a menu...
4,927
Posted By musicmancanora
i found AWK is there a way i can use that to ask...
i found AWK is there a way i can use that to ask for input to search for the account then append LK to lock it delimeted by :
4,927
Posted By musicmancanora
So is there a way to actually write to the shadow...
So is there a way to actually write to the shadow file and prepend LK to the file so you can lock it
without using the commands.
4,927
Posted By musicmancanora
For the project we are doing where not aloud to...
For the project we are doing where not aloud to use any commands like passwd we have to modify the shadow directly they just love making things hard for us :)

Im testing it on my own machine as...
4,927
Posted By musicmancanora
Yehhh but is there a way that i can do it without...
Yehhh but is there a way that i can do it without using passwd -l {username}

like if i can code something to directly modify the shoadow file without using the passwd command

maybe write to the...
4,927
Posted By musicmancanora
Locking specific account without using passwd
Hey guys just wondering how i could lock a specific acount by prepending LK
to the password field in the /etc/shadow file.

it cannot be done through a command since the script gets called by a...
40,029
Posted By musicmancanora
If i do that i get syntax error unexpected token...
If i do that i get syntax error unexpected token 'then'

ahh this is driving me nuts it was working before!


if [ -d /tmp/old ]
then
echo "DIR exist"
else
echo "Error: '$check' does not...
38,557
Posted By musicmancanora
ohhh oko ill give it a try
ohhh oko ill give it a try
38,557
Posted By musicmancanora
is there a way of doing it in the actual bash...
is there a way of doing it in the actual bash script that im running once a month?

like a verbose command or something similar?
38,557
Posted By musicmancanora
Cron jobs redirecting output
Hi guys with regards to Cron jobs if for example i run a script and it produces output to the admin mail how could i stop it from doing that at script level and redirrect it to a file so that admin...
40,029
Posted By musicmancanora
ok that works thanks very much
ok that works thanks very much
40,029
Posted By musicmancanora
that still does not work for some reason i get...
that still does not work for some reason i get more syntax errors with the then
40,029
Posted By musicmancanora
i get syntax error near unexpected token then
i get syntax error near unexpected token then
40,029
Posted By musicmancanora
iv done [code] if [-d /tmp/old] then ...
iv done

[code]
if [-d /tmp/old]
then
#do nothing
elif
echo "directory exists"
exit 1
fi

i get some weird errors all about syntax where am i going wrong
40,029
Posted By musicmancanora
is there a way to check just for directory rather...
is there a way to check just for directory rather then file?

thanks for your fast reply
4,748
Posted By musicmancanora
yes i am talking about a cron job so if this...
yes i am talking about a cron job so if this script where to run as a cron job process and it would send mail to the administrator. I would only want it to send error messages to the log file. Would...
40,029
Posted By musicmancanora
check if a directory exists if not make it
Hey guys im trying to check if the directory exists
i get a syntax error on the elif statement iv tried using else and still same result im not sure. If the directory does not exist can i just...
4,748
Posted By musicmancanora
bash
just bash shell script
4,748
Posted By musicmancanora
stop logging when executing a script
Hi guys if for every command you issued successfully where to be logged from a script and them sent an email to the admistrator how could i stop that so that i wouldnt have to delete admin mail all...
2,071
Posted By musicmancanora
To add to the above if i used a command like ...
To add to the above if i used a command like

mv "whatever the find command fines" /temp/oldfiles

how i would i actually tell the move command to get whatever the find command finds then move...
2,071
Posted By musicmancanora
finding files
Hi guys just wondering if there is a way to
scan the whoel file system and find files that have not been used over a number of days, using the script
4,706
Posted By musicmancanora
The only issue is that we cant do it that way...
The only issue is that we cant do it that way because the Administrators disable cron and at access.
4,706
Posted By musicmancanora
Running scripts unattended
Hi guys just wondering how i could make one of my scripts run unattended without the use of cron?
Showing results 1 to 24 of 24

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