03-15-2009
10.4.11 has support for the recent change to ds, or directory services commands that 10.5.x uses. 10.5 has no NetInfo support.
As a suggestion, you'll probably want to start using the ds commands going forward.
Some of the commands:
dscl . -list /Users
dscl . -read /Groups/admin
dscacheutil -flushcache
...
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I am using HP-UNIX.
I have a requirement as below
I have to change env twice like:
cadenv <env>
cadenv <env>
ccm start -d /dbpath
ccm tar -xvf *.tar
ccm rcv ....
mv *.tar BACKUP
but after I do the first cadenv <env> , I am unable to execute any of the later commands .
... (6 Replies)
Discussion started by: charlei
6 Replies
2. Shell Programming and Scripting
Guys can I change the shell thru script, and after changing i want the script to continue on the previous machine.
Or please suggest other alternative if any???
#!/bin/ksh
HOST=`hostname`
echo "Running the script..."
for MyServer in `cat ServerNames.txt`
do
echo "\n Logging onto... (4 Replies)
Discussion started by: sdosanjh
4 Replies
3. Shell Programming and Scripting
Hello,
I am trying to ssh to a remote machine then change the shell and execute the script. However the ssh session hangs when i try to change the shell
ssh user@host 'csh ; source /home/cshProfile; $HOME/exec.sh'
if i do
ssh user@host ' $HOME/exec.sh'
This works however i... (2 Replies)
Discussion started by: amit1_x
2 Replies
4. UNIX for Dummies Questions & Answers
Hi everybody,
The problem is quite simple, I want to change my default shell which is /bin/csh to /bin/bash. I have looked online for solutions to my problem, but to no avail.
I have tried chsh, but it tells me this:
chsh: can only change local entries; use ypchsh instead.
I use ypchsh,... (7 Replies)
Discussion started by: z1dane
7 Replies
5. Shell Programming and Scripting
Hi,
I want to change the shell prompt, using the cd command.
I have a shell prompt like this -
p78-mfx(dgaw1078/9781)$
Now i do this -
p78-mfx(dgaw1078/9781)$ cd log4j
here the shell prompt should change like this -
p78-mfx(dgaw1078/9781)log4j$ (6 Replies)
Discussion started by: arunkumarmc
6 Replies
6. UNIX for Dummies Questions & Answers
hi guys
I have a user that has been used for long time now that runs o C Shell...
now there is a need to change it to Bash Shell?
Can I cause a problem changing his shell from C to bash?
I mean apps or variables?
thanks a lot (3 Replies)
Discussion started by: karlochacon
3 Replies
7. Shell Programming and Scripting
Hi all,I installed cent OS in my machine. Now when i open the terminal and start writing some commands, then by default with which shell i am working with?
Will i be able to change the shell and then run a few commands? if possible then how to change the shell?
Please reply
Thank you (8 Replies)
Discussion started by: gautamshaw
8 Replies
8. Shell Programming and Scripting
i have created users but those are not listing in HOME directory...and i want to change a shell to another shell...can any one reply me with solutions.. (4 Replies)
Discussion started by: potu@123
4 Replies
9. HP-UX
According to multiple sources you should not change the default shell to bash for the root user because it will make the system unbootable.
Is there a safe way to launch bash for root when logging in? Perhaps I can edit /etc/profile or add it to a startup script somewhere? (2 Replies)
Discussion started by: bstring
2 Replies
10. Shell Programming and Scripting
Hi
We use "tcsh" shell . We do the following steps manually:
> exec ssh-agent zsh
> python "heloo.py" (in the zsh shell)
I am trying to do the steps above from a shell script
This is what I have so far
echo "Executing "
exec ssh-agent zsh
python "hello.py"
exit 0
Problem is... (5 Replies)
Discussion started by: heman82
5 Replies
LEARN ABOUT MOJAVE
lookupd
dscacheutil(1) BSD General Commands Manual dscacheutil(1)
NAME
dscacheutil -- gather information, statistics and initiate queries to the Directory Service cache.
SYNOPSIS
dscacheutil -h
dscacheutil -q category [-a key value]
dscacheutil -cachedump [-buckets] [-entries [category]]
dscacheutil -configuration
dscacheutil -flushcache
dscacheutil -statistics
DESCRIPTION
dscacheutil does various operations against the Directory Service cache including gathering statistics, initiating lookups, inspection, cache
flush, etc. This tool replaces most of the functionality of the lookupd tool previously available in the OS.
FLAGS
A list of flags and their descriptions:
-h Lists the options for calling dscacheutil
-q category
Initiate a query using standard calls. These calls will either return results from the cache or go fetch live data and place them in
the cache. By default if no specific query is requested via -a then all results within that category will be returned.
-a key value
Optional flag to -q for a specific key with a value.
-cachedump
Dumps an overview of the cache by default. Additional flags will provide more detailed information.
-buckets
Used in conjunction with -cachedump to also print hash bucket usage of the current cache.
-entries [category]
Used in conjunction with -cachedump to dump detailed information about cache entries. An optional category can be supplied to only
see types of interest. Dumping 'host' entries can only be done by administrative users.
-configuration
Prints current configuration information, such as the search policy from Directory Service and cache parameters.
-flushcache
Flushes the entire cache. This should only be used in extreme cases. Validation information is used within the cache along with
other techniques to ensure the OS has valid information available to it.
-statistics
Prints statistics from the cache including an overview and detailed call statistics. Some calls are not cached but are derived from
other calls internally. Cache hits and cache misses may not always be equal to external calls. For example getaddrinfo is actually
a combination of gethostbyname with other calls internally to the cache to maximize cache hit rate.
Available categories and associated keys:
group name or gid
host name or ip_address (used for both IPv6 and IPv4)
mount name
protocol name or number
rpc name or number
service name or port
user name or uid
EXAMPLES
Lookup a user:
% dscacheutil -q user -a name jdoe
name: jdoe
password: ********
uid: 501
gid: 501
dir: /Users/jdoe
shell: /bin/csh
gecos: John Doe
Lookup all users:
% dscacheutil -q user
Dump cache overview:
% dscacheutil -cachedump
Dump cache details with user entries:
% dscacheutil -cachedump -entries user
SEE ALSO
DirectoryService(8), dsmemberutil(1)
Darwin Jan 14, 2007 Darwin