Sponsored Content
Operating Systems Solaris Tilde prefix returns invalid home directory. Post 302895986 by jlliagre on Thursday 3rd of April 2014 04:17:42 PM
Old 04-03-2014
An ldap directory used to authenticate users is storing all fields traditionally found in the /etc/passwd plain file. The home directory is definitely one of them but one should only be returned if there is an entry matching the username requested, unless you have a non standard directory server or a custom plugin.
What says:
Code:
ldaplist -v user1

?
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

c++ home directory??

when i compile *.cpp files the compiler didn't find the non standart includes.If i have to put the full path of the includet files where shall i begin from root dirctory or i heve to put includet files in cpp home directory??? can i compile java files in unix(linux mandrake 7) if yes haw... (3 Replies)
Discussion started by: user666
3 Replies

2. Programming

Getting Home Directory

Hi I need to get the home directory of current user who is running the program, also i need to store the value in a particular variable and pass to the function. thanks in advance (4 Replies)
Discussion started by: cutechaps
4 Replies

3. Solaris

Restricting SFTP user to a defined directory and home directory

Hi, I've created solaris user which has both FTP and SFTP Access. Using the "ftpaccess" configuration file options "guest-root" and "restricted-uid", i can restrict the user to a specific directory. But I'm unable to restrict the user when the user is logged in using SFTP. The aim is to... (1 Reply)
Discussion started by: sftpuser
1 Replies

4. Shell Programming and Scripting

for $word in $line returns filenames in the current directory unexpectedly

I am writing a script below, which has 2 loops. The outer one reads file sufffixed with a number and inner inside which loop through each line of the file and display each space delimited string. However, i find that the string printed out in the inner loop includes not only the delimited string in... (2 Replies)
Discussion started by: martie
2 Replies

5. Shell Programming and Scripting

Find all images, append unique prefix to name and move to different directory

Hi, I have a directory with Multiple subdirectories and 1000s of pictures (jpg) in each directory. The problem is that each directory has a 001.jpg in them. I want to append a unique name (the directory_name)would be fine. and then move them to one main backup directory once they have been... (1 Reply)
Discussion started by: kmaq7621
1 Replies

6. Shell Programming and Scripting

rm -rf ab returns find: `./ab': No such file or directory

Hi Gurus. This is driving me a bit batty. I now if must be a simple matter but I cant find anything that references it. I have a housekeeping script that searches for some huge dump directories then removes them using rm -rf. find ./ -name 'ab' -exec rm -rf {} \; This works but always... (7 Replies)
Discussion started by: rinser
7 Replies

7. Shell Programming and Scripting

Extract Uniq prefix from a start and end prefix

Dear All, assume i have a file with content: <Start>6000</Start> <Stop>7599</Stop> the output is: 6000 7000 7100 7200 7300 7400 7599 how should we use any awk, sed, perl can do this task, means to extract the uniq prefixes from the start and stop prefix. Thanks Jimmy (3 Replies)
Discussion started by: jimmy_y
3 Replies

8. Solaris

SunOS confusing root directory and user home directory

Hello, I've just started using a Solaris machine with SunOS 5.10. After the machine is turned on, I open a Console window and at the prompt, if I execute a pwd command, it tells me I'm at my home directory (someone configured "myuser" as default user after init). ... (2 Replies)
Discussion started by: egyassun
2 Replies

9. Windows & DOS: Issues & Discussions

Home Questions Tags Users Unanswered Windows 2016 DNS server returns SERVFAIL for non-existing doma

I have two DNS resolvers in /etc/resolv.conf file. The top one is Windows DNS server, and the bottom one is my wi-fi router. Please see below. nameserver 192.168.1.126 nameserver 192.168.1.1 In Windows DNS server, the sole "Forward Lookup Zone" is biman.net When I query for host in the zone... (6 Replies)
Discussion started by: broy32000
6 Replies
ldaplist(1)							   User Commands						       ldaplist(1)

NAME
ldaplist - search and list naming information from an LDAP directory using the configured profile SYNOPSIS
/usr/bin/ldaplist [-dlv] [database [key]...] /usr/bin/ldaplist -h DESCRIPTION
The ldaplist utility searches for and lists the naming information from the LDAP directory service defined in the LDAP configuration files generated by ldapclient(1M) during the client initialization phase. The Solaris LDAP client must be set up in order to use this utility. The database is either a container name or a database name as defined in nsswitch.conf(4). A container is a non-leaf entry in the Directory Information Tree (DIT) that contains naming service information. The container name is the LDAP Relative Distinguished Name (RDN) of the container relative to the defaultSearchBase as defined in the configuration files. For example, for a container named ou=people, the data- base name is the database specified in nsswitch.conf. This database is mapped to a container, for example, passwd maps to ou=people. If an invalid database is specified, it will be mapped to a generic container, for example, nisMapName=name). The key is the attribute value to be searched in the database. You can specify more than one key to be searched in the same database. The key can be specified in either of two forms: attribute=value or value. In the first case, ldaplist passes the search key to the server. In the latter case, an attribute is assigned depending on how the database is specified. If the database is a container name, then the "cn" attribute type is used. If the database is a valid database name as defined in the nsswitch.conf, then a predefined attribute type is used (see table below). If the database is an invalid database name, then cn is used as the attribute type. The ldaplist utility relies on the Schema defined in the RFC 2307bis, currently an IETF draft. The data stored on the LDAP server must be stored based on this Schema, unless the profile contains schema mapping definitions. For more information on schema mapping see ldap- client(1M). The following table lists the default mapping from the database names to the container, the LDAP object class, and the attribute type used if not defined in the key. Database Object Class Attribute Type Container aliases mailGroup cn ou=Aliases automount nisObject cn automountMapName=auto_* bootparams bootableDevice cn ou=Ethers ethers ieee802Device cn ou=Ethers group posixgroup cn ou=Group hosts ipHost cn ou=Hosts ipnodes ipHost cn ou=Hosts netgroup ipNetgroup cn ou=Netgroup netmasks ipNetwork ipnetworknumber ou=Networks networks ipNetwork ipnetworknumber ou=Networks passwd posixAccount uid ou=People protocols ipProtocol cn ou=Protocols publickey nisKeyObject uidnumber ou=People cn ou=Hosts rpc oncRpc cn ou=Rpc services ipService cn ou=Services printers printerService printer-uri ou=printers auth_attr SolarisAuthAttr nameT ou=SolarisAuthAttr prof_attr SolarisProfAttr nameT ou=SolarisProfAttr exec_attr SolarisExecAttr nameT ou=SolarisProfAttr user_attr SolarisUserAttr uidT ou=people audit_user SolarisAuditUser uidT ou=people o For the automount database, auto_*, in the container column, represents auto_home, auto_direct, ... o For the publickey database, if the key starts with a digit, it will be interpreted as an uid number. If the key starts with a non- digit, it will be interpreted as a host name. The ldaplist utility supports substring search by using the wildcard "*" in the key. For example, "my*" will match any strings that starts with "my". In some shell environments, keys containing the wildcard may need to be quoted. If the key is not specified, all the containers in the current search baseDN will be listed. OPTIONS
The following options are supported: -d Lists the attributes for the specified database, rather than the entries. By default, the entries are listed. -h Lists the database mapping. -l Lists all the attributes for each entry matching the search criteria. By default, ldaplist lists only the Distinguished Name of the entries found. -v Sets verbose mode. The ldaplist utility will also print the filter used to search for the entry. The filter will be prefixed with "+++". EXAMPLES
Example 1: Listing All Entries in the Hosts Database example% ldaplist hosts Example 2: Listing All Entries in a Non-Standard Database ou=new example% ldaplist ou=new Example 3: Finding "user1" in the passwd Database example% ldaplist passwd user1 Example 4: Finding the Entry With Service Port of 4045 in the services Database example% ldaplist services ipServicePort=4045 Example 5: Finding All Users With Username Starting with new in the passwd Database example% ldaplist passwd 'new*' Example 6: Listing the Attributes for the hosts Database example% ldaplist -d hosts EXIT STATUS
The following exit values are returned: 0 Successfully matched some entries. 1 Successfully searched the table and no matches were found. 2 An error occurred. An error message is output. FILES
/var/ldap/ldap_client_file Files that contain the LDAP configuration of the client. Do not manually modify these files. Their content /var/ldap/ldap_client_cred is not guaranteed to be human readable. To update these files, use ldapclient(1M) ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWnisu | +-----------------------------+-----------------------------+ |Interface Stability |Evolving | +-----------------------------+-----------------------------+ SEE ALSO
ldap(1), ldapadd(1), ldapdelete(1), ldapmodify(1), ldapmodrdn(1), ldapsearch(1), idsconfig(1M), ldap_cachemgr(1M), ldapaddent(1M), ldap- client(1M), suninstall(1M), resolv.conf(4), attributes(5) NOTES
RFC 2307bis is an IETF informational document in draft stage that defines an approach for using LDAP as a naming service. SunOS 5.10 16 Jan 2004 ldaplist(1)
All times are GMT -4. The time now is 05:42 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy