Tag Info

New answers tagged

1

Boot the alternate SD Solaris instance and add the line to its /rpool/boot/grub/grub.cfg file. Beware that the file might be overwritten by Solaris should your change something in the boot configuration of this Solaris instance using bootadm or similar.


0

I would have used cibi_seperator="awk" # general case, use plain awk if [ "$SYSTEM_OS" = "SunOS" ]; then cibi_seperator="nawk" elif [ "$SYSTEM_OS" = "fooOS" ]; then cibi_seperator="/bin/special/awk" elif ... fi This way, cibi_seperator is always set, test is done only for OS that need special awk (like solaris).


1

Found out the problem: I set the parameter: SYSTEM_OS=`uname -a` before the if statement. Whereas, I should have set it to: SYSTEM_OS=`uname -s` Sorry for the inconvenience.


0

case "$SYSTEM_OS" in (SunOS) cibi_separator=nawk;; (Linux) cibi_separator=awk;; (*) echo "[$SYSTEM_OS] unsupported"; exit 1;; esac ... $cibi_separator -F, 'NR==1,NR==2{print $0;}' cibi.csv > section_header.csv


0

This blog is misleading as the commands shown are changing the nodename, not the hostname. The nodename match by convention the hostname associated with the primary network interface (if any) but there is no requirement for them to be in sync, especially when the system uses a dynamic network configuration (dhcp). See ...


1

Yes, /etc/inet/hosts (or /etc/hosts) and /etc/inet/ipnodes should be updated manually, they are relative to the network stack and not the hostname of the machine.


2

To find out the names(FMRI) of the SMF services, you can use svcs -a | grep service_name e.g svcs -a | grep ldap Once you know the name of the SMF service name, you can use following to restart that svcadm restart ldap Then you can check the status of the service using svcs ldap A good guide on SMF can be found here ...


4

svcadm restart ldap/client should do the trick. Depending on what you're running you might also need to restart filesystem/autofs


3

Solaris has a built in format command which has analyze and purge subcommands to do this. See https://blogs.oracle.com/cmt/entry/erasing_disks_securely for more information.


0

Qemu-system-sparc64 will boot and run successfully only old versions of Solaris(7< 7 not included) and with custom bios(taken from old Sparc workstations). Of course you can try maybe with next releases versions like Solaris 8 or 9 Remind that the kvm module is only for x86 architecture,so Sparc emulation will be really slow. This is a good how-to to see. ...


6

Here is a portable way: find / -type d -exec test {} = /zones \; -prune -o -type d -print Note that GNU find might be available on an alternate directory depending on the Solaris release you are using (like /usr/sfw/bin/gfind, /usr/gnu/bin/find, ...).


0

This depends on what autofs is mounting. Is it NFS? What security model? If it's AUTH_SYS (IP-based) security, this should work. But if it's krb5, then the SSH server on the host doesn't have a kerberos ticket to mount the directory with.


0

You could change AuthorizedKeysFile to something outside the home directory, for example /etc/ssh/keys/%u/authorized_keys. Then the keys would be available before /home/%u is mounted. From the man page of sshd_config: AuthorizedKeysFile Specifies the file that contains the public keys that can be used for user authentication. The format ...


0

I can only speak to AIX. AIX doesn't have a command that will programatically show the limits. The closest you'll get for AIX is to use this table and code appropriately.


-1

You can use locate. For example: locate .log


0

Your umask is set to 0002, which means it will mask out write permissions for others. In both your examples, the file created is not writable by others. It's working properly.


0

If you would prefer not to invoke a subshell for every single file, this refinement of jlliagre's answer does it all with find predicates, as long as there are no ACLs to make it even more complicated. Correctly handling directories that are readable but not searchable is left as an exercise. If you haven't seen the #! thingy before, it means "don't try to ...


5

Here is a POSIX way to prune any non readable directory with find : find . \( -exec sh -c ' if [ ! -r "$1" ] ; then { exit 1 ; } ; else for i in "$1"/* ; do if [ -d "$i" -a ! -r "$i" ]; then exit 1; fi; done; fi ' sh {} \; -o -prune \) -a -print Note that if this is a full Solaris installation, GNU grep is available in /usr/sfw/bin/ggrep.


1

Just filter them out. find . 2>&1 | grep -v "^find: cannot read dir .*: Permission denied$"


1

Your example shows that you specified -p which the quoted documentation explains copies the file permissions from the source instead of using umask. Remove the -p flag if you want to use the umask instead.


2

cmdk@0,0:h is the driver instance for a disk. Per the Solaris documentation: The cmdk device driver is a common interface to various disk devices. The driver supports magnetic fixed disks and magnetic removable disks.


1

You can test it (and operate on the file if test holds true) in this way: if [ $(((`date +%s` - `stat -c %Y IOstatDisk2.log`) / 60)) -ge 55 ] then echo "File was modified more than 55 minutes ago" # do something with the file... fi


2

GNU find or BSD find will do the trick for you: find <DIRECTORY> -type f -amin +55 -name \*<PATTERN>\* -print this will print all files with name PATTERN in DIRECTORY which where accessed greater than 55 mins ago.



Top 50 recent answers are included