Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
S
scom
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
SulinOS
scom
Commits
b5ca0b44
Kaydet (Commit)
b5ca0b44
authored
May 31, 2007
tarafından
Gürer Özen
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
remoteMount işlemi ctrl-c ile geçilebilsin
üst
9e1cc59b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
13 deletions
+20
-13
mudur.py
mudur/bin/mudur.py
+20
-13
No files found.
mudur/bin/mudur.py
Dosyayı görüntüle @
b5ca0b44
...
...
@@ -680,7 +680,7 @@ def localMount():
ui
.
info
(
_
(
"Activating swap"
))
run
(
"/sbin/swapon"
,
"-a"
)
def
remoteMount
():
def
remoteMount
(
old_handler
):
data
=
loadFile
(
"/etc/fstab"
)
.
split
(
"
\n
"
)
data
=
filter
(
lambda
x
:
not
(
x
.
startswith
(
"#"
)
or
x
==
""
),
data
)
fstab
=
map
(
lambda
x
:
x
.
split
(),
data
)
...
...
@@ -696,16 +696,23 @@ def remoteMount():
ui
.
info
(
_
(
"Starting portmap service for NFS"
))
startServices
([
"portmap"
])
ui
.
info
(
_
(
"Mounting remote filesystems"
))
while
True
:
next_set
=
[]
for
item
in
netmounts
:
ret
=
run_quiet
(
"/bin/mount"
,
item
[
1
])
if
ret
!=
0
:
next_set
.
append
(
item
)
if
len
(
next_set
)
==
0
:
break
netmounts
=
next_set
ui
.
info
(
_
(
"Mounting remote filesystems (CTRL-C stops trying)"
))
try
:
signal
.
signal
(
signal
.
SIGINT
,
old_handler
)
while
True
:
next_set
=
[]
for
item
in
netmounts
:
ret
=
run_quiet
(
"/bin/mount"
,
item
[
1
])
if
ret
!=
0
:
next_set
.
append
(
item
)
if
len
(
next_set
)
==
0
:
break
netmounts
=
next_set
time
.
sleep
(
0.5
)
except
KeyboardInterrupt
:
ui
.
error
(
_
(
"Mounting skipped with CTRL-C, remote shares are not accessible!"
))
time
.
sleep
(
1
)
signal
.
signal
(
signal
.
SIGINT
,
signal
.
SIG_IGN
)
def
hdparm
():
if
config
.
get
(
"safe"
):
...
...
@@ -906,7 +913,7 @@ def except_hook(eType, eValue, eTrace):
# Main program
#
signal
.
signal
(
signal
.
SIGINT
,
signal
.
SIG_IGN
)
old_handler
=
signal
.
signal
(
signal
.
SIGINT
,
signal
.
SIG_IGN
)
signal
.
signal
(
signal
.
SIGQUIT
,
signal
.
SIG_IGN
)
signal
.
signal
(
signal
.
SIGTSTP
,
signal
.
SIG_IGN
)
sys
.
excepthook
=
except_hook
...
...
@@ -1002,7 +1009,7 @@ elif sys.argv[1] == "boot":
ttyUnicode
()
remoteMount
()
remoteMount
(
old_handler
)
setSplash
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment