~ubuntu-branches/ubuntu/intrepid/ifupdown/intrepid-201308281004

« back to all changes in this revision

Viewing changes to ifup.8

  • Committer: Bazaar Package Importer
  • Author(s): Adam Conrad
  • Date: 2005-04-05 10:29:07 UTC
  • Revision ID: james.westby@ubuntu.com-20050405102907-i55swxa6xujotstt
Tags: 0.6.4-4.10ubuntu3
Add a dependency on initscripts (>= 2.85-12) to make sure we get
a working /lib/init/readlink for our scripts (Ubuntu bug #8605)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
.TH ifup 8 "5 April 2004" IFUPDOWN ""
 
1
.TH ifup 8 "22 May 2004" IFUPDOWN ""
2
2
.SH NAME
3
3
ifup \- bring a network interface up
4
4
.PP
5
5
ifdown \- take a network interface down
6
6
.SH SYNOPSIS
7
7
.B ifup 
8
 
.BI "[\-nv] [\-i " FILE "|\-\-interfaces=" FILE "] [\-\-no\-act]"
9
 
.BI "[\-\-verbose] [\-a|" IFACE "]..."
 
8
[\fB\-nv\fR]
 
9
[\fB\-\-no\-act\fR]
 
10
[\fB\-\-verbose\fR]
 
11
[\fB\-i\fR \fIFILE\fR|\fB\-\-interfaces=\fR\fIFILE\fR]
 
12
[\fB\-e\fR \fIFILE\fR|\fB\-\-exclude=\fR\fIIFACE\fR]
 
13
\fB\-a\fR|\fIIFACE\fR...
 
14
.br
 
15
.B ifup 
 
16
\fB\-h\fR|\fB\-\-help\fR
 
17
.br
 
18
.B ifup 
 
19
\fB\-V\fR|\fB\-\-version\fR
10
20
.PP
11
21
.B ifdown
12
 
.BI "[\-nv] [\-i " FILE "|\-\-interfaces=" FILE "] [\-\-no\-act]"
13
 
.BI "[\-\-verbose] [\-a|" IFACE "]..."
 
22
[\fB\-nv\fR]
 
23
[\fB\-\-no\-act\fR]
 
24
[\fB\-\-verbose\fR]
 
25
[\fB\-i\fR \fIFILE\fR|\fB\-\-interfaces=\fR\fIFILE\fR]
 
26
[\fB\-e\fR \fIFILE\fR|\fB\-\-exclude=\fR\fIIFACE\fR]
 
27
\fB\-a\fR|\fIIFACE\fR...
14
28
.SH DESCRIPTION
15
29
The
16
30
.BR ifup " and " ifdown
20
34
.SH OPTIONS
21
35
A summary of options is included below.
22
36
.TP
23
 
.BR "\-h" ", " "\-\-help"
24
 
Show summary of options.
25
 
.TP
26
 
.BR "\-V" ", " "\-\-version"
27
 
Show copyright and version information.
28
 
.TP
29
 
.BR "\-a" ", " "\-\-all"
 
37
.BR \-a ", " \-\-all
30
38
If given to \fBifup\fP, affect all interfaces marked \fBauto\fP.
31
39
Interfaces are brought up in the order in which they are defined
32
40
in /etc/network/interfaces.
33
 
If given to \fBifdown\fP, affect all interfaces.
 
41
If given to \fBifdown\fP, affect all defined interfaces.
34
42
Interfaces are brought down in the order in which they are
35
 
currently listed in the state file.
36
 
.TP
37
 
.BI "\-i " FILE ", \-\-interfaces " FILE
 
43
currently listed in the state file. Only interfaces defined
 
44
in /etc/network/interfaces will be brought down.
 
45
Note that you can exclude some interfaces from being handled in this
 
46
by using 
 
47
.I --exclude
 
48
.TP
 
49
.B \-\-force
 
50
Force configuration or deconfiguration of the interface.
 
51
.TP
 
52
.BR \-h ", " \-\-help
 
53
Show summary of options.
 
54
.TP
 
55
\fB\-i\fR \fIFILE\fR, \fB\-\-interfaces=\fR\fIFILE\fR
38
56
Read interface definitions from 
39
57
.I FILE
40
58
instead of from /etc/network/interfaces.
41
59
.TP
42
 
.BR "\-v" ", " "\-\-verbose"
43
 
Show commands as they are executed.
 
60
\fB\-e\fR \fIIFACE\fR, \fB\-\-exclude=\fR\fIIFACE\fR
 
61
Exclude a given interface
 
62
.I IFACE
 
63
from being managed when doing an operation
 
64
that involves a number of interfaces. It can only be given one 
 
65
string which is supposed to be an interface name. You can
 
66
exclude more than one interface if the name
 
67
given is a substring shared by all of them (for example
 
68
.I eth
 
69
will exclude all ethernet interfaces)
 
70
This option is useful to avoid running "up" or "down" 
 
71
commands for some interfaces when using
 
72
.I --all
44
73
.TP
45
 
.BR "\-n" ", " "\-\-no\-act"
 
74
.BR \-n ", " \-\-no\-act
46
75
Don't configure any interfaces or run any "up" or "down" commands.
47
76
.TP
48
 
.B "\-\-no\-mappings"
 
77
.B \-\-no\-mappings
49
78
Don't run any mappings.  See
50
79
.BR interfaces (5)
51
80
for more information about the mapping feature.
52
81
.TP
53
 
.B "\-\-force"
54
 
Force configuration or deconfiguration of the interface.
 
82
.BR \-V ", " \-\-version
 
83
Show copyright and version information.
 
84
.TP
 
85
.BR \-v ", " \-\-verbose
 
86
Show commands as they are executed.
 
87
.SH EXAMPLES
 
88
.TP
 
89
.B ifup -a
 
90
Bring up all the interfaces defined with
 
91
.I auto
 
92
in 
 
93
.I /etc/network/interfaces
 
94
.TP
 
95
.B ifup eth0
 
96
Bring up interface
 
97
.B eth0
 
98
.TP
 
99
.B ifup eth0=home
 
100
Bring up interface
 
101
.B eth0
 
102
as logical interface
 
103
.B home
 
104
.TP
 
105
.B ifdown -e lo -a
 
106
Bring down all the interfaces defined with
 
107
.I auto
 
108
in 
 
109
.I /etc/network/interfaces
 
110
except for those that begin with 
 
111
.I lo
55
112
.SH NOTES
56
 
The
57
113
.BR ifup " and " ifdown
58
 
programs don't know much about configuring interfaces;
59
 
they run low level utilities such as
 
114
are actually the same program called by different names.
 
115
.P
 
116
The program does not configure network interfaces directly;
 
117
it runs low level utilities such as
60
118
.BR ifconfig " and " route
61
 
to do their dirty work. One of the main advantages to using
62
 
.BR ifup " and " ifdown
63
 
instead of calling the low level utilities directly is that
64
 
.BR ifup " and " ifdown
65
 
allow you to keep all your interface specifications in a single
66
 
easily parsable file.
 
119
to do its dirty work.
67
120
.SH FILES
68
121
.TP
69
122
.I /etc/network/interfaces
75
128
.I /etc/network/ifstate
76
129
current state of network interfaces
77
130
.SH KNOWN BUGS/LIMITATIONS
78
 
In some cases, the state maintained by
79
 
.B ifup
80
 
and
81
 
.B ifdown
82
 
in
83
 
.I /etc/network/ifstate
84
 
might be inconsistent with the actual state of the interfaces.
85
 
If this happens, you might need to either modify the state file 
86
 
directly or manually configure/deconfigure interfaces using
87
 
.BR ifconfig (8)
88
 
or 
89
 
.BR ip (8).
90
 
.P
91
 
The 
92
 
.I /etc/network/ifstate
93
 
file must be writable. In particular, you will not be able to run
94
 
.B ifup
95
 
and
96
 
.B ifdown
97
 
if 
98
 
.I /etc/
99
 
is mounted read-only (for example, during a system recovery). A work-around
100
 
for this issue (reported in Debian bug #84074) is to make
101
 
.B /etc/network/ifstate
102
 
a symbolic link to a writable location.
103
 
.P
104
 
The
105
 
.B ifup
106
 
program itself does not automatically bring up interfaces
 
131
The program keeps records of whether network interfaces are up or down.
 
132
Under exceptional circumstances these records can become
 
133
inconsistent with the real states of the interfaces.
 
134
For example, an interface that was brought up using
 
135
.B ifup
 
136
and later deconfigured using
 
137
.B ifconfig
 
138
will still be recorded as up.
 
139
To fix this you can use the
 
140
.B \-\-force
 
141
option to force
 
142
.B ifup
 
143
or
 
144
.B ifdown
 
145
to run configuration or deconfiguration commands despite what
 
146
it considers the current state of the interface to be.
 
147
.P
 
148
The file
 
149
.I /etc/network/ifstate
 
150
must be writable for
 
151
.B ifup
 
152
or
 
153
.B ifdown
 
154
to work properly.
 
155
If that location is not writable
 
156
(for example, because the root filesystem is mounted read-only
 
157
for system recovery)
 
158
then
 
159
.I /etc/network/ifstate
 
160
should be made a symbolic link to a writable location.
 
161
If that is not possible then you can use the
 
162
.B \-\-force
 
163
option to run configuration or deconfiguration commands
 
164
without updating the file.
 
165
.P
 
166
Note that the program does not run automatically:
 
167
.B ifup
 
168
alone does not bring up interfaces
107
169
that appear as a result of hardware being installed and 
108
170
.B ifdown
109
 
does not automatically bring down interfaces
 
171
alone does not bring down interfaces
110
172
that disappear as a result of hardware being removed.
111
 
If you want to monitor interface state changes you might want to
112
 
consider installing also
 
173
To automate the configuration of network interfaces you need to
 
174
install other packages such as
113
175
.BR hotplug (8)
114
 
and
 
176
or
115
177
.BR ifplugd (8).
116
 
Note that the improper use of
117
 
.B ifupdown
118
 
together with
119
 
.B hotplug
120
 
can result in deadlock between them as described in Debian bug #231197.
121
178
.SH AUTHOR
122
179
The ifupdown suite was written by Anthony Towns <aj@azure.humbug.org.au>.
123
180
.SH SEE ALSO