<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Sun Solaris System Admin &#187; General</title>
	<atom:link href="http://www.sunsolarisadmin.com/category/general/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.sunsolarisadmin.com</link>
	<description>Sun Solaris HowTo's Tips Tricks Tutorials</description>
	<lastBuildDate>Wed, 16 Jun 2010 21:07:06 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
<image>
<link>http://www.sunsolarisadmin.com</link>
<url>http://www.sunsolarisadmin.com/wp-content/mbp-favicon/favicon.ico</url>
<title>Sun Solaris System Admin</title>
</image>
		<item>
		<title>Error &#8216;shmget&#8217; call failed with error number 22 (Invalid argument)</title>
		<link>http://www.sunsolarisadmin.com/general/error-shmget-call-failed-with-error-number-22-invalid-argument/</link>
		<comments>http://www.sunsolarisadmin.com/general/error-shmget-call-failed-with-error-number-22-invalid-argument/#comments</comments>
		<pubDate>Mon, 18 Jan 2010 22:16:04 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[ase]]></category>
		<category><![CDATA[backup]]></category>
		<category><![CDATA[CPU]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[memory]]></category>
		<category><![CDATA[project]]></category>
		<category><![CDATA[shared memory]]></category>
		<category><![CDATA[shmget]]></category>
		<category><![CDATA[solaris]]></category>
		<category><![CDATA[sun]]></category>
		<category><![CDATA[sybase]]></category>

		<guid isPermaLink="false">http://www.sunsolarisadmin.com/?p=108</guid>
		<description><![CDATA[The following  error on the Sybase ASE intalled on Sun Solaris can occur if the Maximum shared memory allocated is max&#8217;d out or if none is allocated, it takes the default value which is &#8220;Total Physical Memory /4&#8243;. Backup Server: 4.142.2.58: [0] The &#8216;shmget&#8217; call failed with error number 22 (Invalid argument). Refer to your [...]]]></description>
			<content:encoded><![CDATA[<p><!--adsense-->The following  error on the Sybase ASE intalled on Sun Solaris can occur if the Maximum shared memory allocated is max&#8217;d out or if none is allocated, it takes the default value which is <strong>&#8220;Total Physical Memory /4&#8243;</strong>.</p>
<blockquote><p><span style="color: #ff0000;"><em>Backup Server: 4.142.2.58: [0] The &#8216;shmget&#8217; call failed with error number 22 (Invalid argument). Refer to your operating system documentation for further details.</em></span></p></blockquote>
<p><span id="more-108"></span>To confirm, if maximum shared memory has been manually set,</p>
<blockquote><p><strong># projects -l</strong></p>
<p>user.asetest<br />
projid : 101<br />
comment: &#8220;Sybase ASE&#8221;<br />
users  : (none)<br />
groups : (none)<br />
attribs: project.max-shm-memory=(privileged,4294967296,deny)</p></blockquote>
<p>For instance, here we have set the Maximum Shared memory to 4GB to the user account which owns and runs the Sybase ASE. And, the last line &#8220;<span style="text-decoration: underline;"><em><strong>attribs: project.max-shm-memory=(privileged,4294967296,deny)</strong></em></span>&#8221; basically, sets the maximum shared memory for the user processes to 4GB (4294967296).</p>
<p>This is equivalent to doing</p>
<blockquote><p><strong># cat /etc/projects</strong></p></blockquote>
<p>If something similar doesn&#8217;t exist then the ASE is using the system defaults.</p>
<p>In any case, we need to increase the Maximum Shared memory. In our case increasing it to 7GB fixed the problem.</p>
<p>To add a new Project entry,</p>
<blockquote><p><strong># projadd -p 101 -U asetest -c &#8220;Sybase ASE&#8221; -K &#8220;max-shm-memory=(privileged,7GB,deny)&#8221; user.asetest</strong></p></blockquote>
<p>This would create a new project with ID 101, name user.asetest for user asetest and set the Maximum Shared Memory to 7GB.</p>
<p>To modify an existing Project entry,</p>
<blockquote><p><strong># projmod -sK &#8220;project.max-shm-memory=(privileged,7GB,deny)&#8221; user.asetest</strong></p></blockquote>
<p>This should help!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.sunsolarisadmin.com/general/error-shmget-call-failed-with-error-number-22-invalid-argument/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Error Could not get shadow information for NOUSER</title>
		<link>http://www.sunsolarisadmin.com/general/error-could-not-get-shadow-information-for-nouser/</link>
		<comments>http://www.sunsolarisadmin.com/general/error-could-not-get-shadow-information-for-nouser/#comments</comments>
		<pubDate>Tue, 12 Jan 2010 20:01:12 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[nouser]]></category>
		<category><![CDATA[shadow]]></category>
		<category><![CDATA[sshd]]></category>
		<category><![CDATA[sun-solaris]]></category>

		<guid isPermaLink="false">http://www.sunsolarisadmin.com/?p=99</guid>
		<description><![CDATA[Have you ever had the following error popup on your /var/adm/messages: Oct  8 12:26:14 myserver sshd[29288]: [ID 800047 auth.error] error: Could not get shadow information for NOUSER It would look like a security incident with the &#8220;nouser&#8221; system account but not so to be. The error gets written to /var/adm/messages when a user tries to [...]]]></description>
			<content:encoded><![CDATA[<p><!--adsense-->Have you ever had the following error popup on your /var/adm/messages:<strong></strong></p>
<p><span style="color: #ff0000;"><strong>Oct  8 12:26:14 myserver sshd[29288]: [ID 800047 auth.error] error: Could not get shadow information for NOUSER</strong></span><strong></strong></p>
<p>It would look like a security incident with the &#8220;<strong>nouser</strong>&#8221; system account but not so to be. The error gets written to /var/adm/messages when a user tries to SSH to the server using a user account which doesn&#8217;t exist on the system (a typo error can contribute) or on your NIS/NIS+ systems.</p>
<p>So no panic!!!!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.sunsolarisadmin.com/general/error-could-not-get-shadow-information-for-nouser/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to find the package which installed a file</title>
		<link>http://www.sunsolarisadmin.com/general/how-to-find-the-package-which-installed-a-file/</link>
		<comments>http://www.sunsolarisadmin.com/general/how-to-find-the-package-which-installed-a-file/#comments</comments>
		<pubDate>Tue, 25 Aug 2009 17:25:35 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[bin]]></category>
		<category><![CDATA[package]]></category>
		<category><![CDATA[solaris pkgchk]]></category>

		<guid isPermaLink="false">http://www.sunsolarisadmin.com/?p=92</guid>
		<description><![CDATA[If you have a file and need to know the package that installed the file on the system then the following procedure using &#8220;pkgchk&#8221; should help. Let&#8217;s look at the &#8220;which&#8221; utility in Solaris and find which package installed the file. The file path for which is /usr/bin/which # which which /usr/bin/which To find the [...]]]></description>
			<content:encoded><![CDATA[<p><!--adsense-->If you have a file and need to know the package that installed the file on the system then the following procedure using &#8220;pkgchk&#8221; should help.</p>
<p><span id="more-92"></span><br />
Let&#8217;s look at the &#8220;which&#8221; utility in Solaris and find which package installed the file.</p>
<p>The file path for which is <strong>/usr/bin/which</strong></p>
<blockquote><p><strong># which which</strong><br />
/usr/bin/which</p></blockquote>
<p>To find the package which installed it use the &#8220;pkgchk&#8221; command with the &#8220;-l&#8221; &#8220;and -p&#8221; options and the full file path of the file as follows,</p>
<blockquote><p><strong># pkgchk -l -p /usr/bin/which</strong><br />
Pathname: /usr/bin/which<br />
Type: regular file<br />
Expected mode: 0555<br />
Expected owner: root<br />
Expected group: bin<br />
Expected file size (bytes): 1288<br />
Expected sum(1) of contents: 25204<br />
Expected last modification: Jan 21 23:32:39 2005<br />
Referenced by the following packages:<br />
<span style="color: #339966;"><em><strong>SUNWcsu</strong></em></span></p></blockquote>
<p>You can see that the which utility is installed by the package<span style="color: #ff0000;"> &#8220;SUNWcsu&#8221;</span>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.sunsolarisadmin.com/general/how-to-find-the-package-which-installed-a-file/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to remove ^M characters from file in Unix/Solaris</title>
		<link>http://www.sunsolarisadmin.com/general/how-to-remove-m-characters-from-file-in-unixsolaris/</link>
		<comments>http://www.sunsolarisadmin.com/general/how-to-remove-m-characters-from-file-in-unixsolaris/#comments</comments>
		<pubDate>Tue, 21 Jul 2009 19:12:43 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[CTRL+M]]></category>
		<category><![CDATA[dos2unix]]></category>
		<category><![CDATA[solaris]]></category>
		<category><![CDATA[string]]></category>
		<category><![CDATA[tr]]></category>
		<category><![CDATA[unix2dos]]></category>
		<category><![CDATA[vi]]></category>

		<guid isPermaLink="false">http://www.sunsolarisadmin.com/?p=81</guid>
		<description><![CDATA[When you sometimes copy a file from Windows to UNIX/Solaris or even Linux systems, you can find these anooying ^M characters everywhere. This is because, the file from Windows is in DOS (ASCII) format and needs to be converted to ISO format. There are many ways to do this. Let&#8217;s start with the easy one [...]]]></description>
			<content:encoded><![CDATA[<p><!--adsense-->When you sometimes copy a file from Windows to UNIX/Solaris or even Linux systems, you can find these anooying ^M characters everywhere. This is because, the file from Windows is in DOS (ASCII) format and needs to be converted to ISO format.</p>
<p><span id="more-81"></span><br />
There are many ways to do this. Let&#8217;s start with the easy one look at each of them</p>
<p><strong>1. Use dos2unix utility<br />
</strong><br />
Solaris pre-installs dos2unix utility into the system to do this job for you. As the name says, it converts the file from DOS format to UNIX format. To do this the syntax is</p>
<blockquote><p><strong># dos2unix &lt;file&gt; &lt;new file&gt;</strong></p></blockquote>
<p>for instance</p>
<blockquote><p><strong># dos2unix test.txt test2.txt</strong></p></blockquote>
<p>Where the test.txt is the file you want the ^M characters removed and test2.txt is the file stripped of the ^M characters.</p>
<p>You may also overwrite the existing file by mentioning the source and destination files as same:</p>
<blockquote><p><strong># dos2unix test.txt test.txt</strong></p></blockquote>
<p><strong>2. Using VI</strong></p>
<p>Open the file with &#8220;vi&#8221; editor and type the following:</p>
<blockquote><p><strong>:%s/^M//g</strong></p></blockquote>
<pre><strong>NOTE: To get the ^M in there, you should type CTRL+V+M</strong></pre>
<p><strong>3. Using &#8220;tr&#8221; utility</strong></p>
<p><strong>&#8220;tr&#8221;</strong> utility is used to translate characters. Using with <strong>&#8220;-d&#8221;</strong> deletes a listed string.</p>
<blockquote><p><strong># tr -d &#8216;\r&#8217; &lt;old.file &gt; &lt;new.file</strong>&gt;</p></blockquote>
<p>Alternatively, use its octel representation as follows:</p>
<blockquote><p><strong># tr -d &#8216;\015&#8242; &lt;old.file &gt; &lt;new.file&gt;</strong></p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.sunsolarisadmin.com/general/how-to-remove-m-characters-from-file-in-unixsolaris/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>psrinfo &#8211; Find number of Physical &amp; Virtual Processors in Solaris 10</title>
		<link>http://www.sunsolarisadmin.com/general/psrinfo-find-number-of-physical-virtual-processors-in-solaris-10/</link>
		<comments>http://www.sunsolarisadmin.com/general/psrinfo-find-number-of-physical-virtual-processors-in-solaris-10/#comments</comments>
		<pubDate>Sat, 03 Jan 2009 01:54:53 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Processor]]></category>
		<category><![CDATA[psrinfo]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[solaris]]></category>
		<category><![CDATA[sparc]]></category>
		<category><![CDATA[sun]]></category>
		<category><![CDATA[sun4v]]></category>
		<category><![CDATA[sunos]]></category>
		<category><![CDATA[SUNW]]></category>
		<category><![CDATA[t5120]]></category>
		<category><![CDATA[t5140]]></category>
		<category><![CDATA[ultrasparc]]></category>
		<category><![CDATA[virtual-processor]]></category>
		<category><![CDATA[x86]]></category>

		<guid isPermaLink="false">http://www.sunsolarisadmin.com/?p=61</guid>
		<description><![CDATA[In Solaris 10, if you want to find the processor type and the number of physical processors installed on the system and the number of Virtual Processors available on the system then the psrinfo command does job for you. To simply display the number of Physical processors, simply run the command with the -p option [...]]]></description>
			<content:encoded><![CDATA[<p><!--adsense-->In Solaris 10, if you want to find the processor type and the number of physical processors installed on the system and the number of Virtual Processors available on the system then the psrinfo command does job for you.</p>
<p><span id="more-61"></span></p>
<p>To simply display the number of Physical processors, simply run the command with the -p option as follows:</p>
<blockquote><p><strong>root@sunserver # psrinfo -p<br />
</strong>2</p></blockquote>
<p>where 2 implies that there are 2 physical processors installed on the system.</p>
<p>If you would like to check the number of Virtual Processors on each of these Physical processors then type the command with the &#8220;-pv&#8221; arguement as follows:</p>
<blockquote><p><strong>root@ server:/root$ uname -a</strong></p>
<p>SunOS server 5.10 Generic_137111-02 sun4v sparc SUNW,SPARC-Enterprise-T5120</p>
<p><strong>root@server:/root$ psrinfo -pv</strong></p>
<p>The physical processor has 32 virtual processors (0-31)</p>
<p>  UltraSPARC-T2 (cpuid 0 clock 1165 MHz)</p></blockquote>
<p>The above indicates that there was only one physical processor (UltraSPARC-T2) on the T5120 server which has 32 Virtual processors. Each virtual processor is an entity with its own interrupt ID, capable of executing independent threads.</p>
<p>In simple terms, the number of Virtual Processors supported by a physical CPU is</p>
<blockquote><p><strong><em>&#8220;Number of Core&#8221; x &#8220;Number of threads&#8221;</em></strong></p></blockquote>
<p>For instance, the above is on a T5120 server with the UltraSPARC-T2. This CPU  has 4 cores and each core can support 8 threads and that gives us 32 Virtual processors.</p>
<p>The number of Virtual processors on a Server is simply the total Virtual processors supported on each of the physical processor.</p>
<p>In the following T5140 server there are 2 Physical UltraSPARC-T2+ processors with 6 cores, each supporting 8 threads which means we get 48 Virtual processors per Physical processor and hence a total of 96 Virtual processors (sum of VPs on individual processors) for the server:</p>
<blockquote><p><strong>root@ bserver:/root$ uname -a</strong></p>
<p>SunOS bserver 5.10 Generic_137111-02 sun4v sparc SUNW,T5140</p>
<p><strong>root@ bserver:/root$ psrinfo -pv</strong></p>
<p>The physical processor has 48 virtual processors (0-23 32-55)</p>
<p>  UltraSPARC-T2+ (cpuid 0 clock 1167 MHz)</p>
<p>The physical processor has 48 virtual processors (64-71 80-119)</p>
<p>  UltraSPARC-T2+ (cpuid 64 clock 1167 MHz)</p></blockquote>
<p>In earlier versions of Solaris, the <strong><em>-p</em></strong> arguement is not supported and hence wouldn&#8217;t provide this summarised output on the counts of the physical and Virtual CPUs.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.sunsolarisadmin.com/general/psrinfo-find-number-of-physical-virtual-processors-in-solaris-10/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>Error:  Your &#8220;crontab&#8221; on  unexpected end of line. This entry has been ignored</title>
		<link>http://www.sunsolarisadmin.com/general/error-your-crontab-on-unexpected-end-of-line-this-entry-has-been-ignored/</link>
		<comments>http://www.sunsolarisadmin.com/general/error-your-crontab-on-unexpected-end-of-line-this-entry-has-been-ignored/#comments</comments>
		<pubDate>Wed, 10 Sep 2008 20:36:51 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[crontab]]></category>
		<category><![CDATA[opensource]]></category>
		<category><![CDATA[solaris]]></category>
		<category><![CDATA[sun]]></category>
		<category><![CDATA[unix]]></category>

		<guid isPermaLink="false">http://www.sunsolarisadmin.com/?p=60</guid>
		<description><![CDATA[Everytime you edit your crontabe file, the error &#8220;Your &#8220;crontab&#8221; on &#60;server&#62; unexpected end of line. This entry has been ignored&#8221; is sent to the users email. This happens if there is a blank line in your crontab file. For instance, in the following crontab file there is a blank line between the last two [...]]]></description>
			<content:encoded><![CDATA[<p><!--adsense-->Everytime you edit your crontabe file, the error <span style="color: #ff0000;"><strong>&#8220;Your &#8220;crontab&#8221; on &lt;server&gt; unexpected end of line. This entry has been ignored&#8221;</strong></span> is sent to the users email. This happens if there is a blank line in your crontab file.</p>
<p><span id="more-60"></span><br />
For instance, in the following crontab file there is a blank line between the last two cron jobs.</p>
<blockquote><p><strong>root@sunsolaris# crontab -l</strong><br />
# The root crontab should be used to perform accounting data collection.<br />
#<br />
# The rtc command is run to adjust the real time clock if and when<br />
# daylight savings time changes.<br />
#<br />
10 1 * * 0,4 /etc/cron.d/logchecker<br />
10 2 * * 0  /usr/lib/newsyslog<br />
15 3 * * 0 /usr/lib/fs/nfs/nfsfind</p>
<p>30 4 * * * /usr/local/bin/disk_check,sh<br />
;;;;<br />
;;;<br />
;;<br />
;</p></blockquote>
<p>To resolve the problem edit the crontab file and look for the blank line and delete the line. In the above, after editing the crontab, it should look lie the follows:</p>
<blockquote><p><strong>root@sunsolaris# crontab -l</strong><br />
# The root crontab should be used to perform accounting data collection.<br />
#<br />
# The rtc command is run to adjust the real time clock if and when<br />
# daylight savings time changes.<br />
#<br />
10 1 * * 0,4 /etc/cron.d/logchecker<br />
10 2 * * 0  /usr/lib/newsyslog<br />
15 3 * * 0 /usr/lib/fs/nfs/nfsfind<br />
30 4 * * * /usr/local/bin/disk_check,sh<br />
;;;<br />
;;<br />
;</p></blockquote>
<p>You can see the  blank line removed from the crontab file.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.sunsolarisadmin.com/general/error-your-crontab-on-unexpected-end-of-line-this-entry-has-been-ignored/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to mount an ISO image in SUN Solaris</title>
		<link>http://www.sunsolarisadmin.com/general/how-to-mount-an-iso-image-in-sun-solaris/</link>
		<comments>http://www.sunsolarisadmin.com/general/how-to-mount-an-iso-image-in-sun-solaris/#comments</comments>
		<pubDate>Sun, 13 Jul 2008 20:16:28 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[CD.DVD]]></category>
		<category><![CDATA[ISO]]></category>
		<category><![CDATA[opensource]]></category>
		<category><![CDATA[solaris]]></category>
		<category><![CDATA[sun]]></category>

		<guid isPermaLink="false">http://www.sunsolarisadmin.com/?p=59</guid>
		<description><![CDATA[In Sun Solaris, we can use the Loopback File driver to mount an ISO image without having to write the ISO image onto a CD or DVD. Following procedure should help you mount an ISO image in Sun Solaris Attach a Block Device sunsolaris# lofiadm -a /export/software/iso_image.iso /dev/lofi/1 Mount the ISO Image block device sunsolaris# [...]]]></description>
			<content:encoded><![CDATA[<p><!--adsense--><br />
In Sun Solaris, we can use the Loopback File driver to mount an ISO image without having to write the ISO image onto a CD or DVD.</p>
<p>Following procedure should help you mount an ISO image in Sun Solaris</p>
<p><span id="more-59"></span></p>
<p><strong><span style="text-decoration: underline;">Attach a Block Device</span></strong></p>
<blockquote><p><strong>sunsolaris# lofiadm -a /export/software/iso_image.iso<br />
</strong>/dev/lofi/1</p></blockquote>
<p><strong><span style="text-decoration: underline;">Mount the ISO Image block device</span></strong></p>
<blockquote><p><strong>sunsolaris# mount -F hsfs -o ro /dev/lofi/1 /mnt</strong></p></blockquote>
<p>Where /mnt is the mount point.</p>
<p>This should mount the ISO image.</p>
<p>To confirm, change directory to /mnt and do a &#8220;ls&#8221; to lis the files</p>
<blockquote><p><strong>sunsolaris# cd /mnt</strong></p>
<p><strong>sunsolaris# ls</strong></p></blockquote>
<p>if at anytime, you want to look at these block devices simply type &#8220;lofiadm&#8221; command with no arguement.</p>
<blockquote><p><strong>sunsolaris# lofiadm</strong><br />
Block Device File<br />
/dev/lofi/1 /export/software/iso_image.iso</p></blockquote>
<p>When we are done with the files on the mounted ISO, we can unmount and detach the Block device we attached earlier:</p>
<blockquote><p><strong>sunsolaris# umount /mnt</strong></p>
<p><strong>sunsolaris# lofiadm -d /dev/lofi/1</strong></p></blockquote>
<p>For instructions on how to mount an ISO image in Linux, <a title="Mount an ISO image in openSUSE &amp; SUSE Linux" href="http://www.susegeek.com/general/how-to-mount-an-iso-image-in-suse-linux-opensuse/" target="_self">click here</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.sunsolarisadmin.com/general/how-to-mount-an-iso-image-in-sun-solaris/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Howto Take Screenshots in Solaris 7/8/9/10 (CDE)</title>
		<link>http://www.sunsolarisadmin.com/general/howto-take-screenshots-in-solaris-78910-cde/</link>
		<comments>http://www.sunsolarisadmin.com/general/howto-take-screenshots-in-solaris-78910-cde/#comments</comments>
		<pubDate>Tue, 13 May 2008 16:55:54 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[CDE]]></category>
		<category><![CDATA[GIMP]]></category>
		<category><![CDATA[Image]]></category>
		<category><![CDATA[magick]]></category>
		<category><![CDATA[solaris]]></category>
		<category><![CDATA[sun]]></category>
		<category><![CDATA[XPR]]></category>
		<category><![CDATA[XWD]]></category>

		<guid isPermaLink="false">http://www.sunsolarisadmin.com/?p=58</guid>
		<description><![CDATA[This is one of those not so technical tip but certainly the one we need when it comes to talk to Sun Support or creating a documentation. yes, its taking screenshots in Sun Solaris Operating Environment using CDE. Sun Solaris X utilities uses &#8220;xwd&#8220;, an application that is standard among the X utilities can be [...]]]></description>
			<content:encoded><![CDATA[<p><!--adsense--><br />
This is one of those not so technical tip but certainly the one we need when it comes to talk to Sun Support or creating a documentation. yes, its taking screenshots in Sun Solaris Operating Environment using CDE. Sun Solaris X utilities uses &#8220;<strong>xwd</strong>&#8220;, an application that is standard among the X utilities can be used to take screenshots. <br id="hea:2" /><br id="hea:3" /><strong>xwd</strong> dumps the output of a window into a file that can be viewed with <strong>xwud</strong>, or converted with convert (part of ImageMagick package), <strong>xv</strong> or another tool to a more usable image type, like png.</p>
<p><span id="more-58"></span><br id="hea:4" /><br id="hea:5" />There are also more convenient tools to make a Screenshot. You should use more reliable import (part of ImageMagick package) instead of xwd. <br id="hea:6" /><br id="hea:7" /><strong><span style="text-decoration: underline;">To Take Screenshot of a Frame</span></strong></p>
<p>When logged onto the CDE, open a terminal session and run the command as follows:</p>
<blockquote><p><strong>sunsolaris# xwd -frame &gt; screenshot.xwd</strong></p></blockquote>
<p>This will prompt you to select a window (the cursor becomes a +), then it will take a picture of the window (as it appears on the screen), the &#8220;-frame&#8221; options will have it also include the window managers decorative borders, then the file is converted to png.<br id="hea:9" /><br id="hea:12" /><strong><span style="text-decoration: underline;">Fullscreen Screenshot</span></strong></p>
<p>A full screen screenshot can be done without any frame being set</p>
<p><strong>sunsolaris# xwd -root &gt; screenshot.xwd</strong></p>
<p><span style="text-decoration: underline;"><strong>Screenshot and Convert togethor</strong></span></p>
<blockquote><p><strong>sunsolaris# xwd -frame | convert xwd:- screenshot.png</strong></p></blockquote>
<p><strong><span style="text-decoration: underline;">Screenshot after &#8220;n&#8221; seconds</span></strong></p>
<p>Now, comes the interesting bit, you can take screenshots after a delay time (say 10 seconds). All you do is to use a sleep command as follows<br id="hea:21" /><br id="hea:22" /><strong>sunsolaris# sleep 10; xwd -root -out screenshot.xwd<br id="hea:23" /></strong></p>
<p><strong><span style="text-decoration: underline;">To print the image captured using Laserjet</span></strong></p>
<p><strong></strong></p>
<blockquote><p><br id="hea:36" /><strong>xpr -device ljet /tmp/myimage | lp -d printer</strong></p></blockquote>
<p>where &#8220;printer&#8221; is the installed printer.<br id="hea:37" /><br id="hea:38" />This file can now be converted to PNG, JPG,GIF using GIMP or any other image editing software.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.sunsolarisadmin.com/general/howto-take-screenshots-in-solaris-78910-cde/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>A quick guide to At jobs in Sun Solaris</title>
		<link>http://www.sunsolarisadmin.com/general/a-quick-guide-to-at-jobs-in-sun-solaris/</link>
		<comments>http://www.sunsolarisadmin.com/general/a-quick-guide-to-at-jobs-in-sun-solaris/#comments</comments>
		<pubDate>Tue, 06 May 2008 19:14:56 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[At-job]]></category>
		<category><![CDATA[Schedule]]></category>
		<category><![CDATA[solaris]]></category>
		<category><![CDATA[sun]]></category>

		<guid isPermaLink="false">http://www.sunsolarisadmin.com/?p=55</guid>
		<description><![CDATA[A quick reference guide for &#8220;at&#8221; utility in Sun Solaris. &#8220;at&#8221; utility in unix is similar to the &#8220;cron&#8221; daemon except for that &#8220;at&#8221; jobs are run only once while cron jobs are recurring. &#8220;at&#8221; is primarily used to schedule a job which can be command or a script to run once at a particular [...]]]></description>
			<content:encoded><![CDATA[<p><!--adsense--><br />
A quick reference guide for &#8220;at&#8221; utility in Sun Solaris. &#8220;at&#8221; utility in unix is similar to the &#8220;cron&#8221; daemon except for that &#8220;at&#8221; jobs are run only once while cron jobs are recurring. &#8220;at&#8221; is primarily used to schedule a job which can be command or a script to run once at a particular time although it can be made to reschedule the job. This could be immediatly or at a later time.</p>
<p>The at utility reads commands from standard input and groups them together as an at job, to be executed at a later time.</p>
<p><span id="more-55"></span></p>
<p><strong><span style="text-decoration: underline;">List AT jobs</span></strong></p>
<p>To list all the at jobs scheduled on the Sun Server</p>
<blockquote><p><strong>sunsolaris# at -l<br />
</strong>user = root     1210161000.a    Wed May  7 12:50:00 2008<br />
user = root     1210161001.a    Wed May  7 12:50:01 2008<br />
user = root     1210198500.a    Wed May  7 23:15:00 2008<br />
user = root     1210331460.a    Fri May  9 12:11:00 2008<br />
user = root     1210198320.a    Wed May  7 23:12:00 2008</p></blockquote>
<p><strong><span style="text-decoration: underline;">To run a command at a particular time</span></strong></p>
<blockquote><p><strong>sunsolaris# at -t 200805072312<br />
</strong>at&gt; reboot<br />
at&gt; &lt;EOT&gt;<br />
  commands will be executed using /sbin/sh<br />
  job 1210198320.a at Wed May  7 23:12:00 2008</p></blockquote>
<p>In the above -t switch defines the time that follows it as the time at which the one or more command that follows at the &#8220;at&gt;&#8221; prompt to be run. Once, all the commands are entered press &#8220;CTRL+D&#8221; to make &#8220;at&#8221; aware of the end of commands.</p>
<p><strong><span style="text-decoration: underline;">Run a job now</span></strong></p>
<blockquote><p><strong>sunsolaris# at now<br />
</strong>at&gt;reboot<br />
at&gt; &lt;EOT&gt;<br />
commands will be executed using /sbin/sh<br />
job 1210100190.a at Tue May  6 19:56:30 2008</p></blockquote>
<p><strong><span style="text-decoration: underline;">Run at noon (12pm)</span></strong></p>
<blockquote><p><strong>sunsolaris# at noon<br />
</strong>at&gt; uname -a<br />
at&gt; &lt;EOT&gt;<br />
commands will be executed using /sbin/sh<br />
job 1210158000.a at Wed May  7 12:00:00 2008</p></blockquote>
<p><strong><span style="text-decoration: underline;">Run at midnight</span></strong></p>
<blockquote><p><strong>sunsolaris# at midnight<br />
</strong>at&gt; uname -a<br />
at&gt; &lt;EOT&gt;<br />
commands will be executed using /sbin/sh<br />
job 1210114800.a at Wed May  7 00:00:00 2008</p></blockquote>
<p><strong><span style="text-decoration: underline;">To run a job &#8220;n&#8221; mins from now</span></strong></p>
<p>Say you want to run the command in 5 minutes from now</p>
<blockquote><p><strong>sunsolaris# at now + 5minutes</strong><br />
at&gt; uname -a<br />
at&gt; &lt;EOT&gt;<br />
commands will be executed using /sbin/sh<br />
job 1210100631.a at Tue May  6 20:03:51 2008</p></blockquote>
<p><strong><span style="text-decoration: underline;">To run a script or a file</span></strong></p>
<blockquote><p><strong>sunsolaris# at -f /root/myscript now</strong></p></blockquote>
<p>The above runs the script /root/myscript immediatly. The switch &#8220;-f&#8221; defines the file to be run instead of commands.</p>
<p><strong><span style="text-decoration: underline;">To remove/cancel an at job</span></strong></p>
<blockquote><p><strong>sunsolaris# at -r &lt;jobname&gt;</strong></p></blockquote>
<p>For instance, in the following list of jobs I want to cancel the last job &#8220;1210100631.a&#8221; job.</p>
<blockquote><p><strong>sunsolaris# at -l<br />
</strong>user = root     1210161000.a    Wed May  7 12:50:00 2008<br />
user = root     1210161001.a    Wed May  7 12:50:01 2008<br />
user = root     1210198500.a    Wed May  7 23:15:00 2008<br />
user = root     1210331460.a    Fri May  9 12:11:00 2008<br />
user = root     1210198320.a    Wed May  7 23:12:00 2008<br />
user = root     1210158000.a    Wed May  7 12:00:00 2008<br />
user = root     1210114800.a    Wed May  7 00:00:00 2008<br />
user = root     1210100631.a    Tue May  6 20:03:51 2008</p>
<p><strong><span style="color: #ff0000;">sunsolaris# at -r 1210100631.a</span></strong></p>
<p><strong>sunsolaris# at -l<br />
</strong>user = root     1210161000.a    Wed May  7 12:50:00 2008<br />
user = root     1210161001.a    Wed May  7 12:50:01 2008<br />
user = root     1210198500.a    Wed May  7 23:15:00 2008<br />
user = root     1210331460.a    Fri May  9 12:11:00 2008<br />
user = root     1210198320.a    Wed May  7 23:12:00 2008<br />
user = root     1210158000.a    Wed May  7 12:00:00 2008<br />
user = root     1210114800.a    Wed May  7 00:00:00 2008</p></blockquote>
<p>Now, you can see the last job removed from the scheduled list.</p>
<p><strong><span style="text-decoration: underline;">at job using a desired shell</span></strong></p>
<p><strong><span style="text-decoration: underline;">To use C shell (csh) </span></strong></p>
<blockquote><p><strong>sunsolaris -c -f /etc/myfile now</strong></p></blockquote>
<p>-c specifies the shell to be used as bash.</p>
<p><strong><span style="text-decoration: underline;">To use bash (sh)</span></strong></p>
<blockquote><p><strong>sunsolaris -s -f /etc/myfile now</strong></p></blockquote>
<p>-s specifies the shell to be used as bash.<br />
<strong><span style="text-decoration: underline;">To email user</span></strong></p>
<p>To email user who scheduled the at job once the at command is run</p>
<blockquote><p><strong>sunsolaris -m -f /etc/myfile now</strong></p></blockquote>
<p>The -m specifies at job to email the user once the job is run.</p>
<p>The at jobs are saved as files under</p>
<blockquote><p><strong>/var/spool/cron/atjobs</strong></p></blockquote>
<p>To see whats in a job, do a &#8220;cat&#8221;</p>
<blockquote><p><strong>sunsolaris# cat 1210114800.a</strong><br />
: at job<br />
: jobname: stdin<br />
: notify by mail: no<br />
: project: 1<br />
export HOME; HOME=&#8217;/&#8217;<br />
export HZ; HZ=&#8221;<br />
export LANG; LANG=&#8217;C&#8217;<br />
export LOGNAME; LOGNAME=&#8217;root&#8217;<br />
export MAIL; MAIL=&#8217;/var/mail/root&#8217;<br />
export PATH; PATH=&#8217;/usr/sbin:/usr/bin&#8217;<br />
export SHELL; SHELL=&#8217;/sbin/sh&#8217;<br />
export TERM; TERM=&#8217;xterm&#8217;<br />
export TZ; TZ=&#8217;GB&#8217;<br />
$SHELL &lt;&lt; &#8216;&#8230;the rest of this file is shell input&#8217;<br />
#ident  &#8220;@(#).proto     1.6     00/05/01 SMI&#8221;   /* SVr4.0 1.2   */<br />
cd /etc/dhcp<br />
umask 22<br />
ulimit unlimited<br />
uname -a</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.sunsolarisadmin.com/general/a-quick-guide-to-at-jobs-in-sun-solaris/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Manually Mount local/remote CDROM in Sun Solaris</title>
		<link>http://www.sunsolarisadmin.com/general/manually-mount-localremote-cdrom-in-sun-solaris/</link>
		<comments>http://www.sunsolarisadmin.com/general/manually-mount-localremote-cdrom-in-sun-solaris/#comments</comments>
		<pubDate>Tue, 29 Apr 2008 19:23:22 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[CDROM]]></category>
		<category><![CDATA[mount]]></category>
		<category><![CDATA[nfs]]></category>
		<category><![CDATA[solaris]]></category>
		<category><![CDATA[sun]]></category>
		<category><![CDATA[VOLD]]></category>
		<category><![CDATA[Volume Management]]></category>

		<guid isPermaLink="false">http://www.sunsolarisadmin.com/?p=52</guid>
		<description><![CDATA[The Volume Manager (vold) daemon in Sun Solaris will automatically detect and mount a CDROM when inserted on Sun Solaris under /cdrom (if CD is not labelled )or /cdrom/&#60;label&#62; where &#60;label&#62; is the label of the CD In instances where vold is not running or when there is a need to manually mount the CDROM [...]]]></description>
			<content:encoded><![CDATA[<p><!--adsense--><br />
The Volume Manager (vold) daemon in Sun Solaris will automatically detect and mount a CDROM when inserted on Sun Solaris under /cdrom (if CD is not labelled )or /cdrom/&lt;label&gt; where &lt;label&gt; is the label of the CD</p>
<p>In instances where vold is not running or when there is a need to manually mount the CDROM the following the procedure should help.</p>
<p><span id="more-52"></span></p>
<p><strong><span style="text-decoration: underline;">Logon to the Sun Server and switch user to root</span></strong></p>
<blockquote><p><strong>sunsolaris$ su -<br />
</strong>Password:</p></blockquote>
<p><strong><span style="text-decoration: underline;">Indentify Device Name for CDROM</span></strong></p>
<p>The device name for the CDROM is normally /dev/dsk/c0t6d0s2. However, you can find this as follows:</p>
<blockquote><p><strong>sunsolaris# ls -al /dev/sr* |awk &#8216;{print &#8220;/&#8221; $11}&#8217;</strong></p></blockquote>
<p>This returns the device name for the CDROM. In my case, /dev/dsk/c0t6d0s2</p>
<p><strong><span style="text-decoration: underline;">Mount CDROM</span></strong></p>
<p>Assuming the mount point &#8220;/cdrom&#8221; already exists, mount the CDROM as follows:</p>
<blockquote><p><strong>sunsolaris# mount -F hsfs -o ro /dev/dsk/c0t6d0s2 /cdrom</strong></p></blockquote>
<p>where <strong>/dev/dsk/c0t6d0s2</strong> is the device name for the CDROM</p>
<p><strong>/cdrom</strong> is the mount point</p>
<p>Now, cd to CDROM to see the files from the CDROM mounted.</p>
<p><strong><span style="text-decoration: underline;">Mounting NFS shared remote CDROM</span></strong></p>
<p>In order to mount a CDROM froma  remote server sharing the CDROM, it has to be exported with root access.  Mount the CDROM from the remote server as follows:</p>
<blockquote><p><strong>sunsolaris# mount remoteserver:/cdrom/cdrom0 /cdrom</strong></p></blockquote>
<p>where <strong>/cdrom/cdrom0</strong> is the sharename on the remote server.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.sunsolarisadmin.com/general/manually-mount-localremote-cdrom-in-sun-solaris/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
