Initial add of defaria.com
[clearscm.git] / defaria.com / blogs / Status / archives / week_2007_07_08.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" id="sixapart-standard">
4 <head>
5    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6    <meta name="generator" content="Movable Type 5.2.3" />
7
8    <link rel="stylesheet" href="http://defaria.com/blogs/Status/styles-site.css" type="text/css" />
9    <link rel="alternate" type="application/atom+xml" title="Atom" href="http://defaria.com/blogs/Status/atom.xml" />
10    <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="http://defaria.com/blogs/Status/index.xml"$>" />
11
12    <title>Status for Andrew DeFaria: July  8, 2007 - July 14, 2007 Archives</title>
13
14    <link rel="start" href="http://defaria.com/blogs/Status/" title="Home" />
15    <link rel="prev" href="http://defaria.com/blogs/Status/archives/week_2007_07_01.html" title="July  1, 2007 - July  7, 2007" />
16    <link rel="next" href="http://defaria.com/blogs/Status/archives/week_2007_07_15.html" title="July 15, 2007 - July 21, 2007" />
17 </head>
18 <body class="layout-one-column">
19    <div id="container">
20       <div id="container-inner" class="pkg">
21
22          <div id="banner">
23             <div id="banner-inner" class="pkg">
24                <h1 id="banner-header"><a href="http://defaria.com/blogs/Status/" accesskey="1">Status for Andrew DeFaria</a></h1>
25                <h2 id="banner-description">Searchable status reports and work log</h2>
26             </div>
27          </div>
28
29          <div id="pagebody">
30             <div id="pagebody-inner" class="pkg">
31                <div id="alpha">
32                   <div id="alpha-inner" class="pkg">
33                      
34                      <p class="content-nav">
35                         <a href="http://defaria.com/blogs/Status/archives/week_2007_07_01.html">&laquo; July  1, 2007 - July  7, 2007</a> |
36                         <a href="http://defaria.com/blogs/Status/">Main</a>
37                         | <a href="http://defaria.com/blogs/Status/archives/week_2007_07_15.html">July 15, 2007 - July 21, 2007 &raquo;</a>
38                      </p>
39                      
40                      
41                      <!--
42 <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
43          xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/"
44          xmlns:dc="http://purl.org/dc/elements/1.1/">
45 <rdf:Description
46     rdf:about="http://defaria.com/blogs/Status/archives/week_2007_07_08.html#entry-000650"
47     trackback:ping="http://defaria.com/mt/mt-tb.cgi/38"
48     dc:title="View space/Locked stream"
49     dc:identifier="http://defaria.com/blogs/Status/archives/week_2007_07_08.html#entry-000650"
50     dc:subject="General Dynamics"
51     dc:description=" Resolved a ticket where the user was unable to deliver due to lock on activity - which is really a lock on the stream Did an analysis of view disk space usage Assisted Kirk and Tom with Clearcase 7.0.1.0..."
52     dc:creator=""
53     dc:date="2007-07-11T17:11:16-06:00" />
54 </rdf:RDF>
55 -->
56
57
58                      <h2 class="date-header">July 11, 2007</h2>
59                      <a id="a000650"></a>
60                      <div class="entry" id="entry-650">
61                         <h3 class="entry-header">View space/Locked stream</h3>
62                         <div class="entry-content">
63                            <div class="entry-body">
64                               <ul>
65   <li>Resolved a ticket where the user was unable to deliver due to lock on activity - which is really a lock on the stream</li>
66
67   <li>Did an analysis of view disk space usage</li>
68
69   <li>Assisted Kirk and Tom with Clearcase 7.0.1.0 installation on Linux</li>
70
71   <li>Fixed problem with ssh public key authentication</li>
72 </ul>
73                               
74                               <h2>View space</h2>
75
76 <p>I looked into the disk space usage on the view2 server (partitions view2a, view2b and view2c0 and find the following:</p>
77
78 <img src="/blogs/images/view2a.jpg"><br>
79 <img src="/blogs/images/view2a_list.jpg"><br>
80 <img src="/blogs/images/view2b.jpg"><br>
81 <img src="/blogs/images/view2b_list.jpg"><br>
82 <img src="/blogs/images/view2c.jpg"><br>
83 <img src="/blogs/images/view2c_list.jpg"><br>
84
85 <h2>View Policy and view_db.crs_file size</h2>
86
87 <p>When you use use dynamic view and <tt>clearmake(1)</tt> to utilize <i>build
88 avoidance</i> by <i>winking </i>in <i>derived objects</i>, Clearcase
89 stores <i>configuration records</i> in the view's storage directory
90 (.s):</p>
91
92 <blockquote>
93
94 <p><small class="AllCaps Text"><b>CONFIGURATION RECORDS.</b></small>
95 The file <b>view_db.crs_file</b> in the <b>.s</b> subdirectory is actually part of the view's database, as described inthe following section. It is the part that stores the configuration records of derived objects built in the view.</p>
96
97 <p>...</p>
98
99 <p><b>view_db.crs_file</b></p>
100
101 <p>Stores the configuration records of nonshareable and unshared derived objects. This file resides in subdirectory <b>.s</b> of the view storage directory, allowing it to be remote.</p>
102
103 <p>Compressed copies of the configuration records are cached in a view-private file, <b>.cmake.state</b>, located in the directory that was current when the build started. This speeds up configuration lookup during subsequent builds in the view.</p>
104
105 </blockquote>
106
107 <p>The view_db.crs_file can get fairly large over time. This is another reason why Rational says that "views should be used like Kleenex".</p>
108
109 <h2>Recovering View Space</h2>
110
111 <p>According to <a
112  href="http://members.cox.net/ejostrander/clearteam/cc_howto.html">Eric J. Ostrander's ClearCase / ClearQuest pages</a>:</p>
113
114 <blockquote>
115
116 <h3> Release view database disk space back to the system.</h3>
117
118 <p>As data is collected in a view, the view's database increases in size. Commands such as view_scrubber that remove DOs from a view merely release logical space inside the view's database. That is, the disk space taken by the database does not shrink. This is true for the <i>view-storage</i>/db/* files and the <i>view-storage</i>/.s/view_db.crs_file file (which contains the derived object configuration records). To actually release that
119 space back to the system, one needs to run recoverview twice on that view. Normally recoverview is only needed when a VOB is no longer available and the view's view-private files that once belonged to the VOB are now stranded. However, it has the added benefit that it calls reformatview, which in turn cleans up the database.</p>
120
121 <p>The recoverview must be run twice. The first pass releases any unused space in the database back to the system and cleans up CRs no longer attached to a DO. The second pass releases the now newly unused space (freed up in the first pass) back to the system. A third run has no affect.</p>
122
123 <p>An attempt to run reformatview by itself (which is actually the only part that is really needed) will result in the message "reformat not needed for view". Unfortunately,  reformatview does not have a -force option, but recoverview does.</p>
124
125 <div class=code><pre>
126 # ct recoverview -force -tag <i>view-tag</i>
127 # ct recoverview -force -tag <i>view-tag</i>
128 </pre></div>
129
130 <p><b>NOTE:</b> Running recoverview does not affect view-private files.</p>
131
132 <p><b><font color="red">WARNING!</font></b> Rational recommends not being
133 anywhere in the <i>view-storage</i>area during the recoverview/reformatview (reason unknown).</p>
134 </blockquote>
135
136 <h3>Clearcase 7.0.1.0 Installation on Linux</h3>
137
138 <p>In installing Clearcase 7.0.1.0 on Linux, Kirk and Tom were having problems getting it set up as a registry server. One problem was that they incorrectly named the config file rgy_srv.conf instead of rgy_svr.conf (I always get those wrong myself). There also seems to be an issue where there are two directories, both under /var/adm/rational/clearcase, one named rgy (where the registry is stored) and one named config (where other config files are stored). And there are additional config files related to the registry, rgy_hosts.conf and rgy_region.conf. As it seems to turn out those three files (rgy_svr.conf, rgy_hosts.conf and rgy_region.conf) need to be in both the rgy and config directories under /var/adm/rational/clearcase. Is this new for 7.0.1.0?</p>
139
140 <p>Turns out I was mistaken. While I was working on this so was Kirk. So our actions overlapped and effected each other. The real thing is that these rgy_*.conf files rightfully moved from the rgy directory to the conf directory for 7.0.</p>
141                               
142                               <p class="entry-footer">
143                                  <span class="post-footers">Posted by  at  5:11 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000650.html">Permalink</a>
144                                  
145                                  | <a href="http://defaria.com/blogs/Status/archives/000650.html#trackback">TrackBacks (0)</a>
146                               </p>
147                            </div>
148                         </div>
149                      </div>
150                      
151                      <!--
152 <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
153          xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/"
154          xmlns:dc="http://purl.org/dc/elements/1.1/">
155 <rdf:Description
156     rdf:about="http://defaria.com/blogs/Status/archives/week_2007_07_08.html#entry-000649"
157     trackback:ping="http://defaria.com/mt/mt-tb.cgi/37"
158     dc:title="Removed views/documented customizing Unix environments"
159     dc:identifier="http://defaria.com/blogs/Status/archives/week_2007_07_08.html#entry-000649"
160     dc:subject="General Dynamics"
161     dc:description=" Worked with Tom and Bryce to remove views from p57707 Wrote a document describing how to customize your Unix CDE environment..."
162     dc:creator=""
163     dc:date="2007-07-10T16:17:52-06:00" />
164 </rdf:RDF>
165 -->
166
167
168                      <h2 class="date-header">July 10, 2007</h2>
169                      <a id="a000649"></a>
170                      <div class="entry" id="entry-649">
171                         <h3 class="entry-header">Removed views/documented customizing Unix environments</h3>
172                         <div class="entry-content">
173                            <div class="entry-body">
174                               <ul>
175   <li>Worked with Tom and Bryce to remove views from p57707</li>
176
177   <li>Wrote a document describing how to customize your Unix CDE environment</li>
178 </ul>
179                               
180                               <h3>Removing views with pending deliveries</h3>
181
182 <p>Had an issue where a user (p57707) had left the company but still had UCM related views. In attempting to remove those views to free up space I was told that there was a delivery in progress. Yet if I set to that view and did ct deliver -cancel it would say that there was no delivery in progress. The best thing to do here is to do a ct lsact -cact which should be the deliver activity. Then find which view these was delivered from. IOW this view was the destination view for the delivery and we needed to find where the delivery was initiated from.  Then ct deliver -cancel|-resume from that stream/view.</p>
183
184 <h3>Tips on Personalizing your Unix/CDE environment</h3>
185
186 <p>Way back in the day I used to alpha test HP's VUE which latter became the basis for CDE. Oh yes it's brought back memories for sure, and a couple of head scratches as I strive to remember how to configure, customize and personalize things. Perhaps you too have wished to make the environment a little better. Well here's some tips...</p>
187
188 <h3>Get control of your X Resources</h3>
189
190 <p>A lot of CDE and X can be controlled via X Resources. But how do you manage your X resources in a CDE environment? In general, xrdb(1) is your friend. CDE saves your "session" using X resource files that are loaded via xrdb(1) at session start up. Additionally (I believe) that X loads any and all resources in ~/.Xresources at start. So the trick is to get all your X resources into ~/.Xresources and to start actively managing them. You can do this as follows:</p>
191
192 <div class=code><pre>
193 $ xrdb -q &gt; ~/.Xresources
194 </pre></div>
195
196 <p>Now you can add and/or adjust resources in to your liking then do xrdb -l ~/.Xresources. Remember, xrdb -l ~/.Xresources will always get you back to your <i>known set</i> of X Resources.</p>
197
198 <h3>To find if a resource is set</h3>
199
200 <p>You can see if a resource is set by using the following:</p>
201
202 <div class=code><pre>
203 $ xrdb -q | grep -i &lt;<i>resource string</i>&gt;
204 </pre></div>
205
206 <p>I've attached my ~/.Xresources. Let me bring a few to your attention. Note that resources that start with "*" are global in nature. Thus "*background: &lt;<i>color</i>&gt;" will serve as the background for any X application that doesn't explicitly set a background color. "*"'s between resource names are more general than "."'s. Just think "*" expands to anything where "." expands to one character.</p>
207
208 <p>The "Dtwm*0*backdrop*image: NoBackdrop" says not to set a CDE "Backdrop" on any of the workspaces. Instead I use xv to randomly change my backdrops from jpg images. More on that later...</p>
209
210 <h3>Using Xresource Classes</h3>
211
212 <p>Rather than start Xterms (or dtterms) with:</p>
213
214 <div class=code><pre>
215 $ xterm -fg white -bg black -sl 5000 -cr green \
216 &gt; -sb -e rsh &lt;other machine&gt;
217 $ xterm -fg yellow -bg blue -sl 5000 -sb -e rsh &lt;other machine&gt;
218 </pre></div>
219
220 <p>thus having long lists of options, classify your resources such as:</p>
221
222 <div class=code><pre>
223 XServer*background:    Black
224 XServer*foreground:    Green
225 XServer*colorBD:       Yellow
226 XServer*colorUL:       Red
227 XServer*cursorColor:   Yellow
228 </pre></div>
229
230 <p>Then use xterm -name XServer and all of those X Resources that start with, in this case, XServer will be used. You can set generic or global resources such as;</p>
231
232 <div class=code><pre>
233 XTerm*saveLines:      5000
234 XTerm*scrollbar:      True
235 </pre></div>
236
237 <h3>Setting Meta (or the Diamond key) to be Emacs mode Meta key</h3>
238
239 <p>Did you know that (even in tcsh) generally Emacs key bindings are in effect at the command line. This while arrow up gets you the previous command in the command history stack so does Cntl-P also go to the previous command. Other Emacs bindings that work:</p>
240
241 <ul>
242   <li>C-p: Previous command in history stack</li>
243   <li>C-n: Next command in history stack</li>
244   <li>C-a: Go to beginning of line</li>
245   <li>C-e: Go to end of line</li>
246   <li>C-f: Go forward one character</li>
247   <li>M-f: Go forward one word</li>
248   <li>C-b: Go backward one character</li>
249   <li>M-b: Go backward one word</li>
250   <li>C-d: Delete one character</li>
251   <li>M-d: Delete one word</li>
252   <li>C-t: Transpose two characters</li>
253 </ul>
254
255 <p>Additionally, in bash, C-r stands for search backward in the history stack. tcsh does not support this. Using such keybindings keeps your hands on the keyboard and improves your productivity.</p>
256
257 <p>M-f listed above means "hold the meta key down and type f". The meta key is defined as Escape, which, unfortunately will repeat if held down. Most people map this to the "Alt" key. The Sun keyboard has both an Alt key and two "Diamond" keys that are normally labeled Alt on PC keyboards. Therefore it's good to configure your terminal emulator to
258 use this Diamond/Alt key as Emacs' Meta key. To do this for Xterm use the following X resource (best put into your ~/.Xresouces):</p>
259
260 <div class=code><pre>
261 Xterm*eightBitInput: True
262 </pre></div>
263
264 <p>and Dtterm:</p>
265
266 <div class=code><pre>
267 Dtterm*kshMode: True
268 </pre></div>
269
270 <p>Side note about "kshMode". This is a misnomer really. True, ksh does support Emacs style keybindings (set -o emacs or set -o vi for you vi guys) and it is useful to have Alt =&gt; Meta. However ksh is not the only shell that this is useful for. It is also useful for tcsh and bash, for example.</p>
271
272 <h3>Taking Control of your Buttons and Keybindings</h3>
273
274 <p>The following:</p>
275
276 <div class=code><pre>
277 Dtwm*keyBindings:    MyKeys
278 Dtwm*buttonBindings: MyButtons
279 </pre></div>
280
281 <p>Tell the window manager (Dtwm) not to use the default keyBindings and buttonBindings but instead to use MyKeys and MyButtons instead. These are defined in your dtwmrc, which is under ~/.dt/en_US.ISO8859-1/dtwmrc (which I've also attached). I started by copying the system dtwmrc (cp /usr/dt/config/C/sys.dtwmrc ~/.dt/en_US.ISO8859-1) and then modified it.</p>
282
283 <p>You're dtwmrc can be very complicated. See dtwmrc(1) for more info. Here are MyButtons:</p>
284
285 <div class=code><pre>
286 Buttons MyButtons
287 {
288   &lt;Btn1Down&gt;        root              f.menu Terminals
289   &lt;Btn1Down&gt;        window|frame|icon f.raise
290   &lt;Btn2Click&gt;       root              f.toggle_frontpanel
291   &lt;Btn3Down&gt;        root              f.menu  DtRootMenu
292   &lt;Btn3Down&gt;        icon              f.post_wmenu
293   Shift&lt;Btn1Click&gt;  frame|icon        f.lower
294   &lt;Btn1Click&gt;       frame|icon|window f.raise
295   &lt;Btn1Click2&gt;      frame             f.maximize
296   &lt;Btn1Click2&gt;      icon              f.restore
297   &lt;Btn2Click&gt;       frame|icon        f.raise_lower
298   &lt;Btn3Down&gt;        frame|icon        f.post_wmenu
299   Alt&lt;Btn1Click&gt;    frame|icon|window f.raise
300   Alt&lt;Btn1Click2&gt;   frame|window      f.minimize
301   Alt&lt;Btn1Click2&gt;   icon              f.restore
302   Alt&lt;Btn2Click&gt;    frame|icon        f.raise_lower
303   Alt&lt;Btn1Down&gt;     frame|icon|window f.move
304   Alt&lt;Btn3Down&gt;     window            f.minimize
305 }
306 </pre></div>
307
308 <p>Many of these are taking from the defaults. Here are some of the changes I made:</p>
309
310 <ul>
311   <li>Changed Btn1Down to bring up the "Terminals" menu</li>
312   <li>Added "window" to the places where a Btn1Down would do a raise. This allows me to click on the window itself to raise it instead of having to find the window border.</li>
313 </ul>
314
315 <h3>Changing your desktop background</h3>
316
317 <p>I have a series of images that I like to constantly refresh on my background. I put them in ~/Images. CDE has terrible desktop background support (like circa 1990) and only supports xpm (which is a horrible image file format!). xv is an image viewer than handles more modern image file formats such as .gif, .jpg, and .png. It also has options
318 for setting the backdrop (provided CDE is not putting up a .xpm backdrop image, hence the "Dtwm*0*backdrop*image: NoBackdrop" setting). Now how do we get this to do this periodically?</p>
319
320 <p>The answer? Perl. I've attached a Perl script that sets your backdrop by choosing a random image from all of those under ~/Images every hour or whenever it receives a SIGUSR2.</p>
321
322 <p>Oh and if you wish feel free to:</p>
323
324 <div class=code><pre>
325 $ mkdir ~/Images
326 $ cp ~p6238c/Images ~/Images
327 </pre></div>
328
329 <p>Or</p>
330
331 <div class=code><pre>
332 $ ln -s ~p6258c/Images ~/Images
333 </pre></div>
334
335 <div class=code><pre>
336 *0*ColorPalette:        SoftBlue.dp
337 *0*ColorUse:    HIGH_COLOR
338 *DtEditor*textFontList: -dt-interface user-medium-r-normal-s*-*-*-*-*-*-*-*-*:
339 *DtTerm*shadowThickness:        1
340 *Font:  -dt-interface user-medium-r-normal-s*-*-*-*-*-*-*-*-*
341 *FontList:      -dt-interface system-medium-r-normal-s*-*-*-*-*-*-*-*-*:
342 *FontSet:       -dt-interface user-medium-r-normal-s*-*-*-*-*-*-*-*-*
343 *HelpColorUse:  1
344 *XmText*FontList:       -dt-interface user-medium-r-normal-s*-*-*-*-*-*-*-*-*:
345 *XmText*Translations:   #override\n\
346         Ctrl<Key>u:delete-to-start-of-line()\n\
347         Ctrl<Key>k:delete-to-end-of-line()\n\
348         Ctrl<Key>a:beginning-of-line()\n\
349         Ctrl<Key>e:end-of-line()\n\
350         Ctrl<Key>p:process-up()\n\
351         Ctrl<Key>b:backward-character()\n\
352         Ctrl<Key>n:process-down()\n\
353         Ctrl<Key>f:forward-character()
354 *XmTextField*FontList:  -dt-interface user-medium-r-normal-s*-*-*-*-*-*-*-*-*:
355 *XmTextField*Translations:      #override\n\
356         Ctrl<Key>u:delete-to-start-of-line()\n\
357         Ctrl<Key>k:delete-to-end-of-line()\n\
358         Ctrl<Key>a:beginning-of-line()\n\
359         Ctrl<Key>e:end-of-line()\n\
360         Ctrl<Key>b:backward-character()\n\
361         Ctrl<Key>f:forward-character()
362 *background:    #9494D5D5DFDF
363 *buttonFontList:        -dt-interface system-medium-r-normal-s*-*-*-*-*-*-*-*-*:
364 *dtEnvMapForRemote:     DTAPPSEARCHPATH:DTHELPSEARCHPATH:DTDATABASESEARCHPATH:XMICONSEARCHPATH:XMICONBMSEARCHPATH
365 *enableBtn1Transfer:    button2_transfer
366 *enableButtonTab:       True
367 *enableCDEColorFactors: True
368 *enableDefaultButton:   True
369 *enableDragIcon:        True
370 *enableEtchedInMenu:    True
371 *enableMenuInCascade:   True
372 *enableMultiKeyBindings:        True
373 *enableThinThickness:   True
374 *enableToggleColor:     True
375 *enableToggleVisual:    True
376 *enableUrlAwareness:    True
377 *fontGroup:     Courier
378 *foreground:    #000000000000
379 *labelFontList: -dt-interface system-medium-r-normal-s*-*-*-*-*-*-*-*-*:
380 *loginShell:    True
381 *multiClickTime:        500
382 *promptDialog.bboard.frame.form.text.columns:   45
383 *saveLines:     500
384 *scrollBar_right:       True
385 *sessionVersion:        3.0
386 *systemFont:    -dt-interface system-medium-r-normal-s*-*-*-*-*-*-*-*-*:
387 *textFontList:  -dt-interface user-medium-r-normal-s*-*-*-*-*-*-*-*-*:
388 *ttyModes:      intr ^c quit ^\\ erase ^h kill ^u eof ^d start ^q stop ^s susp ^z dsusp ^y rprnt ^r flush ^o weras ^w lnext ^v
389 *userFont:      -dt-interface user-medium-r-normal-s*-*-*-*-*-*-*-*-*:
390 *xineramaDefaultFramebuffer:    0
391 Dtstyle*timeoutScale:   5
392 Dtwm*0*FrontPanel*geometry:     +67-4
393 Dtwm*0*helpResources:   \n  
394 Dtwm*0*initialWorkspace:        ws0
395 Dtwm*0*workspaceCount:  4
396 Dtwm*0*workspaceList:   "ws0" "ws1" "ws2" "ws3"
397 Dtwm*0*backdrop*image:  NoBackdrop
398 Dtwm*0*ws3*title:       Four
399 Dtwm*0*ws4*title:       New
400 Dtwm*0*ws5*title:       New_1
401 Dtwm*0*ws6*title:       New_2
402 Dtwm*focusAutoRaise:    False
403 Dtwm*gwmOnFrontPanel:   False
404 twm*moveOpaque: True
405 Dtwm*showSwitchArea:    True
406 Dtwm*syncDesktopSwitch: False
407 Dtwm*useSameBackdrop:   True
408 Dtwm.keyboardFocusPolicy:       pointer
409
410 ! Dtwm
411 Dtwm*keyBindings:       MyKeys
412 Dtwm*buttonBindings:    MyButtons
413
414 ! Rxvt
415 Rxvt*font:              "Lucida Console-*-16"
416 Rxvt*font1:             "Lucida Console-*-18"
417 Rxvt*font2:             "Lucida Console-*-20"
418 Rxvt*saveLines:         5000
419 Rxvt*scrollBar_right:   True
420 Rxvt*geometry:          80x24
421 Rxvt*loginShell:        True
422 Rxvt*background:        SteelBlue
423 Rxvt*foreground:        White
424  Rxvt*colorBD:          Red
425 Rxvt*colorUL:           Red
426 Rxvt*cursorColor:       Red
427
428 ! New server
429 Jupiter*background:     MidNightBlue
430 Jupiter*foreground:     White
431 Jupiter*colorBD:        Red
432 Jupiter*colorUL:        Red
433 Jupiter*cursorColor:    Yellow
434
435 ! Danni's desktop
436 Starbase*background:    MediumVioletRed
437 Starbase*foreground:    White
438 Starbase*colorBD:       Yellow
439 Starbase*colorUL:       Red
440 Starbase*cursorColor:   Yellow
441
442 ! Hewlett Packard
443 Tiburon*background:     Black
444 Tiburon*foreground:     Magenta
445 Tiburon*colorBD:        Yellow
446 Tiburon*colorUL:        Red
447 Tiburon*cursorColor:    Green
448
449 Pacifica*background:    ForestGreen
450 Pacifica*foreground:    White
451 Pacifica*colorBD:       Red
452 Pacifica*colorUL:       Red
453 Pacifica*cursorColor:   Red
454
455 plebld01*background:    Black
456 plebld01*foreground:    Yellow
457 plebld01*colorBD:       Yellow
458 plebld01*colorUL:       Red
459 plebld01*cursorColor:   Yellow
460
461 ccase-sj1-4*background: Black
462 ccase-sj1-4*foreground: Green
463 ccase-sj1-4*colorBD:    Green
464 ccase-sj1-4*colorUL:    Red
465 ccase-sj1-4*cursorColor:Yellow
466
467 XServer*background:     Black
468 XServer*foreground:     Green
469 XServer*colorBD:        Yellow
470 XServer*colorUL:        Red
471 XServer*cursorColor:    Yellow
472
473 ! XTerm
474 XTerm*Font:             -*-Lucida Sans Typewriter-medium-r-*-*-*-*-*-*-*-*-*
475 XTerm*saveLines:        5000
476 XTerm*scrollBar_right:  True
477 XTerm*scrollBar:        True
478 XTerm*geometry:         80x24
479 XTerm*loginShell:       True
480 XTerm*background:       SteelBlue
481 XTerm*foreground:       White
482 XTerm*colorBD:          Blue
483 XTerm*colorUL:          Red
484 XTerm*cursorColor:      Yellow
485 XTerm*eightBitInput:    False
486
487 ! XEmacs
488 Emacs*Background:       Gray
489 Emacs*Font:             -*-Lucida Sans Typewriter-medium-r-*-*-*-*-*-*-*-*-*
490
491 ! Dtterm
492 Dtterm*kshMode:         True
493 </pre></div>
494
495 <div class=code><pre>
496 Menu DtRootMenu 
497 {
498   "Menu"                f.title
499   "Applications"        f.menu ApplicationsMenu
500   "Terminals"           f.menu Terminals
501   "Files"               f.menu FilesMenu
502   "Folders"             f.menu FoldersMenu
503   "Hosts"               f.menu HostsMenu
504   "Tools"               f.menu ToolsMenu
505   "Windows"             f.menu WindowsMenu
506   "Lock"                f.action LockDisplay
507   "Suspend"             f.action SDTsuspend
508 }
509
510 Menu Terminals
511 {
512   "Terminals"           f.title
513   sep                   f.separator
514   "Local X Term"        f.action Xterm
515   "Remote X Term"       f.action XtermRlogin
516   sep                   f.separator
517   "Local DT Term"       f.action Dtterm
518   "Remote DT Term"              f.action DttermRlogin
519 }
520
521 Menu WindowsMenu
522 {
523     "Windows"           f.title
524     "Refresh"           f.refresh
525     "Arrange Icons"     f.pack_icons
526     "Restart"           f.restart
527     "Update"            f.action UpdateWorkspaceMenu
528     "Kill"              f.exec /usr/openwin/bin/xkill
529 }
530
531 Menu ApplicationsMenu
532 {
533   "Applications"        f.title
534   "Application Manager" f.action Dtappmgr
535   "Audio Control"       f.action SDtAudioControl
536   "Audio and Video"     f.action SDTjmplay
537   "Calculator"          f.action Dtcalc
538   "Calendar"            f.action Dtcm
539   "Icon Editor"         f.action Dticon
540   "Image Viewer"        f.action SDTimage
541   "Snapshot"            f.action SDTsnapshot
542   "Text Editor"         f.action TextEditor
543   "Text Note"           f.action Note
544   "Voice Note"          f.action Record
545 }
546
547 Menu FilesMenu
548 {
549   "Files"               f.title
550   "File Manager"        f.action Dtfile
551   "Find File"           f.action SDtFind
552   "Properties..."       f.action FileProperties
553 }
554
555 Menu FoldersMenu
556 {
557   "Folders"             f.title
558   "Empty Trash Can"     f.action DtEmptyTrash
559   "File Manager - Home" f.action DtfileHome
560   "Open Floppy"         f.action OpenFloppy
561   "Removable Media"     f.action Dtmediamgr
562   "Trash Can"           f.action Dttrash
563 }
564
565 Menu HostsMenu
566 {
567   "Hosts"               f.title
568   "Find Host..."        f.action HOST_Find
569   "Performance Meter"   f.action SDtPerfmeter
570   "Terminal Console"    f.action DttermConsole
571   "This Host"           f.action Terminal "/usr/dt/config/C/wsmenu/Hosts/This_Host"
572   "Workstation Info"    f.action SDtWsinfo
573 }
574
575 Menu ToolsMenu
576 {
577   "Tools"                       f.title
578   "Create Action"               f.action Dtcreate
579   "Desktop Controls"            f.action DtControls
580   "Hotkey Editor"               f.action SDtHotkey
581   "Power Manager"               f.action SDTpowermgr
582   "Print Manager"               f.action DtPrintManager
583   "Printer Administrator"       f.action PrinterAdministratorDtspcd
584   "Process Manager"             f.action SDtProcess
585   "Solaris Management Console"  f.action smc
586   "Terminal"                    f.action Terminal
587   "Watch Errors"                f.action DttermErrorlog
588 }
589
590 Menu DtPanelMenu
591 {
592   "Windows"                             f.title
593   "Shuffle Up"                          f.circle_up
594   "Shuffle Down"                        f.circle_down
595   "Refresh"                             f.refresh
596   "Clean Up Icons"                      f.pack_icons
597   "Minimize/Restore Front Panel"        f.toggle_frontpanel
598   "Restart Workspace Manager..."        f.restart
599   "Update Workspace Menu"               f.action UpdateWorkspaceMenu
600   "Disable Access Control"              f.action Xhost+
601   "Enable Access Control"               f.action Xhost-
602   "Kill Window..."                      f.exec /usr/openwin/bin/xkill
603 }
604
605 Menu WindowMenu
606 {
607   "Restore"             _R                      f.normalize
608   "Move"                _M                      f.move
609   "Size"                _S                      f.resize
610   "Minimize"            _n                      f.minimize
611   "Maximize"            _x                      f.maximize
612   "Lower"               _L                      f.lower
613   "Workspace..."        _W                      f.workspace_presence
614   "All Workspaces"      _A                      f.occupy_all
615   "Remove Workspace"    _e                      f.remove
616   "Close"               _C      Alt<Key>F4      f.kill
617 }
618
619 Keys MyKeys
620 {
621   # Global
622   #Alt<Key>Menu                 root|icon|window        f.toggle_frontpanel 
623   Alt<Key>Tab                   root|icon|window        f.next_key
624   Alt Shift<Key>Tab             root|icon|window        f.prev_key
625   Alt<Key>Escape                root|icon|window        f.next_key
626   Alt Shift<Key>Escape          root|icon|window        f.prev_key
627   Alt<Key>Down                  root|icon|window        f.circle_down
628   Alt<Key>Up                    root|icon|window        f.circle_up
629   Alt<Key>Left                  root|icon|window        f.prev_workspace
630   Alt<Key>Right                 root|icon|window        f.next_workspace
631   Alt Ctrl Shift<Key>exclam     root|icon|window        f.set_behavior
632
633   # Root
634   <Key>SunAgain                 root|ifkey              f.pack_icons
635   <Key>SunProps                 root|ifkey              f.version
636   <Key>SunUndo                  root|ifkey              f.refresh
637   <Key>SunFront                 root|ifkey              f.circle_up
638   Shift<Key>SunFront            root|ifkey              f.circle_down
639   <Key>Down                     root                    f.circle_down
640   <Key>Up                       root                    f.circle_up
641   <Key>Right                    root                    f.next_workspace
642   <Key>Left                     root                    f.prev_workspace
643   #
644   <Key>SunAudioMute             root|icon|window|ifkey  f.exec /usr/dt/appconfig/sdtvolctl/muteVolume
645   <Key>SunAudioRaiseVolume      root|icon|window|ifkey  f.exec /usr/dt/appconfig/sdtvolctl/volumeUp
646   <Key>SunAudioLowerVolume      root|icon|window|ifkey  f.exec /usr/dt/appconfig/sdtvolctl/volumeDown
647   # Window/Icon
648   <Key>SunFront                 window|icon|ifkey       f.raise_lower
649   <Key>SunOpen                  window|ifkey            f.minimize
650   Shift<Key>Escape              window|icon             f.post_wmenu
651   Alt<Key>space                 window|icon             f.post_wmenu
652   Alt<Key>F6                    window                  f.next_key transient
653   Alt Shift<Key>F6              window                  f.prev_key transient
654   Alt<Key>F4                    window|icon|ifkey       f.kill
655   Alt<Key>SunProps              window|icon|ifkey       f.workspace_presence
656   Alt<Key>SunPaste              window|icon|ifkey       f.occupy_all
657   Alt<Key>SunCut                window|icon|ifkey       f.remove
658   Alt<Key>KP_Insert             window|icon             f.occupy_all
659   Alt<Key>Delete                window|icon             f.remove
660   Ctrl<Key>L2                   window|ifkey            f.next_cmap
661   Ctrl<Key>L4                   window|ifkey            f.prev_cmap
662   # Icon
663   <Key>SunOpen                  icon|ifkey              f.restore
664   Alt<Key>F4                    icon|ifkey              f.kill
665   <Key>SunProps                 icon|ifkey              f.workspace_presence
666   <Key>SunPaste                 icon|ifkey              f.occupy_all
667   <Key>SunCut                   icon|ifkey              f.remove
668   <Key>KP_Insert                icon|ifkey              f.occupy_all
669   <Key>Delete                   icon|ifkey              f.remove
670 }
671
672 Buttons MyButtons
673 {
674   <Btn1Down>            root                    f.menu Terminals
675   <Btn1Down>            window|frame|icon       f.raise
676   <Btn2Click>           root                    f.toggle_frontpanel
677   <Btn3Down>            root                    f.menu  DtRootMenu
678   <Btn3Down>            icon            f.post_wmenu
679   Shift<Btn1Click>      frame|icon              f.lower
680   <Btn1Click>           frame|icon|window       f.raise
681   <Btn1Click2>          frame                   f.maximize
682   <Btn1Click2>          icon                    f.restore
683   <Btn2Click>           frame|icon              f.raise_lower
684   <Btn3Down>            frame|icon              f.post_wmenu
685   Alt<Btn1Click>        frame|icon|window       f.raise
686   Alt<Btn1Click2>       frame|window            f.minimize
687   Alt<Btn1Click2>       icon                    f.restore
688   Alt<Btn2Click>        frame|icon              f.raise_lower
689   Alt<Btn1Down>         frame|icon|window       f.move
690   Alt<Btn3Down>         window                  f.minimize
691 }
692
693 Menu DefaultWindowMenu
694 {
695   "Restore"     _R      Alt<Key>F5      f.normalize
696   "Move"        _M      Alt<Key>F7      f.move
697   "Size"        _S      Alt<Key>F8      f.resize
698   "Minimize"    _n      Alt<Key>F9      f.minimize
699   "Maximize"    _x      Alt<Key>F10     f.maximize
700   "Lower"       _L      Alt<Key>F3      f.lower
701   "Close"       _C      Alt<Key>F4      f.kill
702 }
703 </pre></div>
704
705 <div class=code><pre>
706 #!/bin/perl
707 use strict;
708 use warnings;
709 use POSIX qw (setsid);
710
711 use FindBin;
712
713 my $sleep = 60 * 60;
714 my $home = $ENV{HOME};
715 my $xv = "/prj/Synopsis/gccsparcOS5/ccss/utils/xv/xv";
716
717 my @images = `ls $home/Images`;
718 chomp @images;
719
720 my $arch             = $^O =~ /MSWin/  ? "windows"   :
721                        $^O =~ /cygwin/ ? "cygwin"    : $^O;
722 my $null             = $^O =~ /MSWin/  ? "NUL"       : "/dev/null";
723
724 sub display_err ($;$$) {
725   my ($msg, $handle, $nolinefeed) = @_;
726
727   $handle = *STDERR if !defined $handle;
728
729   print $handle $msg;
730   print $handle "\n" if !defined $nolinefeed;
731 } # display_err
732
733 sub error ($;$$$) {
734   my ($msg, $errno, $handle, $nolinefeed) = @_;
735
736   if (!$errno) {
737     $msg = "$FindBin::Script ERROR: $msg";
738   } else {
739     $msg = "$FindBin::Script ERROR #$errno: $msg";
740   } # if
741
742   display_err $msg, $handle, $nolinefeed;
743
744   exit $errno if $errno;
745 } # error
746
747 sub EnterDaemonMode (;$$) {
748   my ($logfile, $errorlog) = @_;
749
750   if (!defined $logfile or $logfile eq '') {
751     $logfile = $null;
752   } # if
753
754   if (!defined $errorlog or $errorlog eq '') {
755     $errorlog = $null;
756   } # if
757
758   # Change the current directory to /
759   my $root = $arch eq "windows" ? "C:\\" : "/";
760   chdir $root
761     or error "Can't chdir to $root ($!), 1";
762
763   # Turn off umask
764   umask 0;
765
766   # Redirect STDIN to $null
767   open STDIN, $null
768     or error "Can't read $null ($!)", 1;
769
770   # Redirect STDOUT to logfile
771   open STDOUT, ">>$logfile"
772     or error "Can't write to $logfile ($!), 1";
773
774   # Redirect STDERR to errorlog
775   open STDERR, ">>$errorlog"
776     or error "Can't write to $errorlog ($!)", 1;
777
778   # Now fork the daemon
779   defined (my $pid = fork)
780     or error "Can't create daemon ($!)", 1;
781
782   # Now the parent exits
783   exit if $pid;
784
785   # Set process to be session leader
786   setsid ()
787     or error "Can't start a new session ($!)", 1;
788 } # EnterDaemonMode
789
790 sub SwitchWallPaper {
791   # We don't need to do anything here, just handle the interrupt and
792   # let the while loop continue.
793 } # SwitchWallPaper
794
795 $SIG{USR2} = \&SwitchWallPaper;
796  
797 EnterDaemonMode;
798
799 while () {
800   my $cmd = "$xv -root -maxpect -quit $home/Images/" . $images [int (rand $#images)];
801
802   `$cmd`;
803
804   sleep $sleep;
805 } # while
806 </pre></div>
807                               
808                               <p class="entry-footer">
809                                  <span class="post-footers">Posted by  at  4:17 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000649.html">Permalink</a>
810                                  
811                                  | <a href="http://defaria.com/blogs/Status/archives/000649.html#trackback">TrackBacks (0)</a>
812                               </p>
813                            </div>
814                         </div>
815                      </div>
816                      
817                   </div>
818                </div>
819             </div>
820          </div>
821       </div>
822    </div>
823 </body>
824 </html>