1 | <sect2><title> </title><para> </para></sect2>
|
---|
2 |
|
---|
3 | <sect2><title>Configuring Glibc</title>
|
---|
4 |
|
---|
5 | <para>We need to create the <filename>/etc/nsswitch.conf</filename> file,
|
---|
6 | because, although Glibc provides defaults when this file is missing or corrupt,
|
---|
7 | the Glibc defaults don't work well with networking. Also, our time zone needs
|
---|
8 | to be set up.</para>
|
---|
9 |
|
---|
10 | <para>Create a new file <filename>/etc/nsswitch.conf</filename> by running the
|
---|
11 | following:</para>
|
---|
12 |
|
---|
13 | <screen><userinput>cat > /etc/nsswitch.conf << "EOF"</userinput>
|
---|
14 | # Begin /etc/nsswitch.conf
|
---|
15 |
|
---|
16 | passwd: files
|
---|
17 | group: files
|
---|
18 | shadow: files
|
---|
19 |
|
---|
20 | publickey: files
|
---|
21 |
|
---|
22 | hosts: files dns
|
---|
23 | networks: files
|
---|
24 |
|
---|
25 | protocols: db files
|
---|
26 | services: db files
|
---|
27 | ethers: db files
|
---|
28 | rpc: db files
|
---|
29 |
|
---|
30 | netgroup: db files
|
---|
31 |
|
---|
32 | # End /etc/nsswitch.conf
|
---|
33 | <userinput>EOF</userinput></screen>
|
---|
34 |
|
---|
35 | <para>To find out what time zone you're in, run the following script:</para>
|
---|
36 |
|
---|
37 | <screen><userinput>tzselect</userinput></screen>
|
---|
38 |
|
---|
39 | <para>When you've answered a few questions about your location, the script will
|
---|
40 | output the name of your time zone, something like <emphasis>EST5EDT</emphasis>
|
---|
41 | or <emphasis>Canada/Eastern</emphasis>. Then create the
|
---|
42 | <filename>/etc/localtime</filename> file by running:</para>
|
---|
43 |
|
---|
44 | <screen><userinput>cp --remove-destination /usr/share/zoneinfo/Canada/Eastern /etc/localtime </userinput></screen>
|
---|
45 |
|
---|
46 | <para>The meaning of the option:</para>
|
---|
47 |
|
---|
48 | <itemizedlist>
|
---|
49 | <listitem><para><userinput>--remove-destination</userinput>: This is needed to
|
---|
50 | force removal of the already existing symbolic link. The reason why we copy
|
---|
51 | instead of symlink is to cover the situation where <filename>/usr</filename> is
|
---|
52 | on a separate partition. This could matter, for example, when booted into single
|
---|
53 | user mode.</para></listitem>
|
---|
54 | </itemizedlist>
|
---|
55 |
|
---|
56 | <para>Of course, instead of <emphasis>Canada/Eastern</emphasis>, fill in
|
---|
57 | the name of the time zone that the <userinput>tzselect</userinput> script
|
---|
58 | gave you.</para>
|
---|
59 |
|
---|
60 | </sect2>
|
---|
61 |
|
---|
62 | <sect2><title> </title><para> </para></sect2>
|
---|
63 |
|
---|
64 | <sect2>
|
---|
65 | <title>Configuring Dynamic Loader</title>
|
---|
66 |
|
---|
67 | <para>By default, the dynamic loader
|
---|
68 | (<filename>/lib/ld-linux.so.2</filename>) searches through <filename
|
---|
69 | class="directory">/lib</filename> and <filename
|
---|
70 | class="directory">/usr/lib</filename> for dynamic libraries that are needed
|
---|
71 | by programs when you run them. However, if there are libraries in
|
---|
72 | directories other than <filename class="directory">/lib</filename> and
|
---|
73 | <filename class="directory">/usr/lib</filename>, you need to add them to
|
---|
74 | the <filename>/etc/ld.so.conf</filename> file for the dynamic
|
---|
75 | loader to find them. Two directories that are commonly known to contain
|
---|
76 | additional libraries are <filename
|
---|
77 | class="directory">/usr/local/lib</filename> and <filename
|
---|
78 | class="directory">/opt/lib</filename>, so we add those directories to the
|
---|
79 | dynamic loader's search path.</para>
|
---|
80 |
|
---|
81 | <para>Create a new file <filename>/etc/ld.so.conf</filename> by running the
|
---|
82 | following:</para>
|
---|
83 |
|
---|
84 | <screen><userinput>cat > /etc/ld.so.conf << "EOF"</userinput>
|
---|
85 | # Begin /etc/ld.so.conf
|
---|
86 |
|
---|
87 | /usr/local/lib
|
---|
88 | /opt/lib
|
---|
89 |
|
---|
90 | # End /etc/ld.so.conf
|
---|
91 | <userinput>EOF</userinput></screen>
|
---|
92 |
|
---|
93 | </sect2>
|
---|
94 |
|
---|