Initial add of defaria.com
[clearscm.git] / defaria.com / blogs / Status / archives / 000510.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: More module coding</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/000509.html" title="More Clearcase modules" />
16    <link rel="next" href="http://defaria.com/blogs/Status/archives/000511.html" title="Mail.pm/CQ Web" />
17
18    
19
20    
21
22    <script type="text/javascript" src="http://defaria.com/blogs/Status/mt-site.js"></script>
23 </head>
24 <body class="layout-one-column" onload="individualArchivesOnLoad(commenter_name)">
25    <div id="container">
26       <div id="container-inner" class="pkg">
27
28          <div id="banner">
29             <div id="banner-inner" class="pkg">
30                <h1 id="banner-header"><a href="http://defaria.com/blogs/Status/" accesskey="1">Status for Andrew DeFaria</a></h1>
31                <h2 id="banner-description">Searchable status reports and work log</h2>
32             </div>
33          </div>
34
35          <div id="pagebody">
36             <div id="pagebody-inner" class="pkg">
37                <div id="alpha">
38                   <div id="alpha-inner" class="pkg">
39
40                      <p class="content-nav">
41                         <a href="http://defaria.com/blogs/Status/archives/000509.html">&laquo; More Clearcase modules</a> |
42                         <a href="http://defaria.com/blogs/Status/">Main</a>
43                         | <a href="http://defaria.com/blogs/Status/archives/000511.html">Mail.pm/CQ Web &raquo;</a>
44                      </p>
45
46                      <a id="a000510"></a>
47                      <div class="entry" id="entry-510">
48                         <h3 class="entry-header">More module coding</h3>
49                         <div class="entry-content">
50                            <div class="entry-body">
51                               <ul>
52   <li>Standardized some modules a little bit</li>
53
54   <li>Added much more functionality to Clearcase modules and tied that into stats and log_activity</li>
55
56   <li>Changed the startup of many scripts to be more standard</li>
57
58   <li>Implemented much more functionality in stats</li>
59 </ul>
60                            </div>
61                            <div id="more" class="entry-more">
62                               <h2>Odd characters in view tags</h2>
63
64 <p>I found this odd view tag in the <span>SanJoseNT</span> region: 
65
66 <div class="code"><pre>
67 ccase-sj1-1:ct lsview -long -region SanJoseNT helenay_PIRelease_12022002_7031RC\)
68 Tag: helenay_PIRelease_12022002_7031RC)
69   Global path: \\Pc-1ubrv\Myview\helenay.v.vws
70   Server host: Pc-1ubrv
71   Region: SanJoseNT
72   Active: NO
73   View tag uuid:132d6e50.0eee11d7.a7a4.00:b0:d0:20:ba:8a
74 View on host: Pc-1ubrv
75 View server access path: F:\Myview\helenay.v.vws
76 View uuid: 132d6e50.0eee11d7.a7a4.00:b0:d0:20:ba:8a
77 View attributes: snapshot
78 View owner: BROADCOM\helenay
79 </pre></div>
80
81 <p>Note the trailing ")" in the view tag. Alas this screws up Perl scripts when one may take a view tag and include it in a cleartool cmd:</p>
82
83 <div class="code"><pre>
84 `cleartool lsview -long -region SanJoseNT $view_tag 2&gt; /dev/null`
85 </pre></div>
86
87 <p>when $view_tag is the above results in:</p>
88
89 <div class="code"><pre>
90 sh: -c: line 1: syntax error near unexpected token `)'
91 sh: -c: line 1: `cleartool lsview -long -region SanJoseNT helenay_PIRelease_12022002_7031RC) 2&gt; /dev/null'
92 </pre></div>
93
94 <p>I don't think I should write code to escape such characters but what else can I do? We could ask this user to rename their view but apparently  Clearcase does not disallow such strange characters in view tag names (and perhaps other objects...).</p>
95
96 <h2>DNS Issues</h2>
97
98 <p>Kerrynn De Roche wrote:</p>
99
100 <blockquote type="cite">
101   <p>I just checked the etc/hosts and it seems we had last set the entries to 128.34 instead of 128.37. I changed them to 128.37 and it seems to be working now...</p>
102 </blockquote>
103
104 <p>10.136.128.37 has always been the IP address of ccase-rmna-4. If you
105 had previously had 10.138.128.34 then that was what was wrong (with
106 that workaround).</p>
107
108 <blockquote type="cite">
109   <p>I would rather not have to worry about having to check the hosts file  whenever the IP address changes though.</p>
110 </blockquote>
111
112 <p>You see that's the difference between desktops and servers - server IP
113 addresses never (or at least rarely) change. In fact in the administration business, keeping the servers IP address static is always a consideration - even if the machine is being swapped. We'll swap the IP addresses in DNS to the new machine to keep them the same precisely because of these issues. ccase-rmna-4's IP address will not change!</p>
114
115 <blockquote type="cite">
116   <p>What is the method you use to not have to worry about hosts file?</p>
117 </blockquote>
118
119 <p>As I said, in my environment it works without /etc/hosts:</p>
120
121 <div class="code"><pre>
122 <font color="#3333ff"><b>Local:</b></font><u>cat /etc/hosts</u>
123 # Copyright (c) 1993-1999 Microsoft Corp.
124 #
125 # This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
126 #
127 # This file contains the mappings of IP addresses to host names. Each
128 # entry should be kept on an individual line. The IP address should
129 # be placed in the first column followed by the corresponding host name.
130 # The IP address and the host name should be separated by at least one
131 # space.
132 #
133 # Additionally, comments (such as these) may be inserted on individual
134 # lines or following the machine name denoted by a '#' symbol.
135 #
136 # For example:
137 #
138 #      102.54.94.97     rhino.acme.com          # source server
139 #       38.25.63.10     x.acme.com              # x client host
140 127.0.0.1       localhost laptop
141 #10.136.128.37  ccase-rmna-4
142 </pre></div>
143
144 <p>Note ccase-rmna-4's entry is commented out. Additionally I do not have
145 ca.broadcom.com on the DNS Suffix Search List:</p>
146
147 <div class="code"><pre>
148 <font color="#3333ff"><b>Local:</b></font><u>ipconfig /all</u>
149
150 Windows IP Configuration
151
152         Host Name . . . . . . . . . . . . : LTSJCA-ADEFARIA
153         Primary Dns Suffix  . . . . . . . : corp.ad.broadcom.com
154         Node Type . . . . . . . . . . . . : Hybrid
155         IP Routing Enabled. . . . . . . . : No
156         WINS Proxy Enabled. . . . . . . . : No
157         <font color="#ff0000"><b>DNS Suffix Search List. . . . . . : corp.ad.broadcom.com
158                                             broadcom.com</b></font>
159
160 Ethernet adapter Wireless:
161
162         Media State . . . . . . . . . . . : Media disconnected
163         Description . . . . . . . . . . . : Broadcom 802.11g Network
164 Adapter
165         Physical Address. . . . . . . . . : 00-10-18-90-1D-11
166
167 Ethernet adapter Secondary:
168
169         Media State . . . . . . . . . . . : Media disconnected
170         Description . . . . . . . . . . . : 3Com 3C920 Integrated Fast Ethernet        Controller (3C905C-TX Compatible) #2
171         Physical Address. . . . . . . . . : 00-08-74-95-4A-24
172
173 Ethernet adapter Primary:
174
175         Connection-specific DNS Suffix  . : broadcom.com
176         Description . . . . . . . . . . . : 3Com 3C920 Integrated Fast Ethernet        Controller (3C905C-TX Compatible)
177         Physical Address. . . . . . . . . : 00-B0-D0-0E-A2-71
178         Dhcp Enabled. . . . . . . . . . . : Yes
179         Autoconfiguration Enabled . . . . : Yes
180         IP Address. . . . . . . . . . . . : 10.16.65.219
181         Subnet Mask . . . . . . . . . . . : 255.255.240.0
182         Default Gateway . . . . . . . . . : 10.16.64.1
183         DHCP Server . . . . . . . . . . . : 10.16.192.15
184         DNS Servers . . . . . . . . . . . : 10.16.64.11
185                                             10.16.64.12
186                                             10.16.64.13
187         Primary WINS Server . . . . . . . : 10.16.192.15
188         Secondary WINS Server . . . . . . : 10.16.192.16
189         Lease Obtained. . . . . . . . . . : Tuesday, January 03, 2006 8:29:46 PM
190         Lease Expires . . . . . . . . . . : Friday, January 06, 2006 8:29:46 PM
191 </pre></div>
192
193 <p>So I don't have any kind of workaround any more. It just works. By that
194 I mean the following command used to fail stating a  WINSOCK error trying to contact ccase-rman-4:</p>
195
196 <div class="code"><pre>
197 <font color="#3333ff"><b>Local:</b></font><u>ct lsstream -invob \\rmna_projects</u>
198 </pre></div>
199
200 <p>(Note ct is aliased to cleartool and since I'm using Cygwin "\\" collapses to a single "\"). Now this command works for me. Note that nslookup of a bare ccase-rmna-4 still fails for me:</p>
201
202 <div class="code"><pre>
203 <font color="#3333ff"><b>Local:</b></font><u>nslookup ccase-rmna-4</u>
204 *** dns-sj1-1b.sj.broadcom.com can't find ccase-rmna-4: Non-existent domain
205 Server:  dns-sj1-1b.sj.broadcom.com
206 Address:  10.16.64.11
207 </pre></div>
208
209 <p>This is because ccase-rmna-4 (and  case-rmna-4.corp.ad.broadcom.com and ccase-rmna-4.broadcom.com from the DNS Suffix Search List) don't exist - it should be  case-rmna-4.ca.broadcom.com. But a FQDN works:</p>
210
211 <div class="code"><pre>
212 <font color="#3333ff"><b>Local:</b></font><u>nslookup ccase-rmna-4.ca.broadcom.com</u>
213 Non-authoritative answer:
214 Server:  dns-sj1-1b.sj.broadcom.com
215 Address:  10.16.64.11
216
217 Name:    ccase-rmna-4.ca.broadcom.com
218 Address:  10.136.128.37
219 </pre></div>
220
221 <p>The way resolver(3) (DNS's name resolution) works is to look at files like /etc/hosts and/or apply DNS Suffix Search Lists. So if DNS found ccase-rmna-4 in /etc/hosts it would have it's IP address. Otherwise it'll take a bare hostname of ccase-rmna-4 and append the suffixes. So if you added ca.broadcom.com to the list that also should work.</p>
222
223 <p>However the whole reason that Clearcase is using ccase-rmna-4 is
224 because that's what <b>was</b> listed in the vob tag:</p>
225
226 <div class="code"><pre>
227 <font color="#3333ff"><b>Local:</b></font><u>llvob \\rmna_projects</u>
228 Tag: \rmna_projects
229   Global path: \\cc-rmna-storage\ccstgloc-cabu\vobstore\rmna_projects.vbs
230   Server host: ccase-rmna-4.ca.broadcom.com
231   Access: public
232   Mount options: 
233   Region: rmnaNT
234   Active: NO
235   Vob tag replica uuid: 088b79e0.0b0c11d9.9204.00:01:80:c8:b5:2d
236   <font color="#ff0000"><b>Vob on host: ccase-rmna-4.ca.broadcom.com</b></font>
237 Vob server access path: /projects/ccstgloc-<span>cabu</span>/vobstore/rmna_projects.vbs
238 Vob family uuid:  09d0e19e.8b6611d5.b03b.00:01:80:c8:b5:2d
239 Vob replica uuid: 088b79e0.0b0c11d9.9204.00:01:80:c8:b5:2d
240 Vob registry attributes: ucmvob,replicated
241 </pre></div>
242
243 <p>but as you can see we fully qualified ccase-rmna-4 to ccase-rmna-4.ca.broadcom.com. This means that this <b>should</b> work
244 without an /etc/host workaround or an "add to DNS Suffix Search List"
245 workaround. Why that's not working remains a mystery.
246                            </div>
247                         </div>
248                         <p class="entry-footer">
249                            <span class="post-footers">Posted by  on January  4, 2006  6:19 PM</span> <span class="separator">|</span> <a class="permalink" href="http://defaria.com/blogs/Status/archives/000510.html">Permalink</a>
250                         </p>
251                      </div>
252
253                      
254
255                      
256                   </div>
257                </div>
258             </div>
259          </div>
260       </div>
261    </div>
262 </body>
263 </html>