204 |
|
|
205 |
my $cmd; |
my $cmd; |
206 |
|
|
207 |
|
my $umlowner = $vhost->{main}{'owner'}; |
208 |
|
$cmd = "$chown -R $umlowner.$umlowner $vhost_path"; |
209 |
|
askCmd("do it", $cmd, "changing ownership of uml directory"); |
210 |
|
#exit; |
211 |
|
|
212 |
#print "\n\n"; |
#print "\n\n"; |
213 |
|
|
214 |
my $cmd_screen = "$screen -m -d -S $vhost_name "; |
my $cmd_screen = "$screen -m -d -S $vhost_name "; |
215 |
|
|
216 |
|
# was: $cmd_screen $cmd_prefix $linux \\ |
217 |
|
|
218 |
my $start_cmd = " |
my $start_cmd = " |
219 |
$cmd_screen $cmd_prefix $linux \\ |
$cmd_screen $cmd_prefix \\ |
220 |
|
$vhost->{'kernel'} \\ |
221 |
mem=$vhost->{'mem'} \\ |
mem=$vhost->{'mem'} \\ |
222 |
umid=$vhost->{'umid'} \\ |
umid=$vhost->{'umid'} \\ |
223 |
uml_dir=$vhost_path/var \\ |
uml_dir=$vhost_path/var \\ |
224 |
$host_device=tuntap,$device_bridge \\ |
$host_device=tuntap,$device_bridge \\ |
225 |
ubd0=$vhost_path/rootfs/$vhost->{'rootfs'} \\ |
ubd0=$vhost_path/rootfs/$vhost->{'rootfs'} \\ |
226 |
ubd1=$vhost_path/$vhost->{'swapfs'} \\ |
ubd1=$vhost_path/$vhost->{'swapfs'} \\ |
227 |
ubd2=$vhost_path/datafs/$vhost->{'datafs'}"; # > $vhost_path/boot.msg &"; |
ubd2=$vhost_path/datafs/$vhost->{'datafs'} \\ |
228 |
|
ubd3=$vhost_path/datafs/$vhost->{'datafs2'}"; # > $vhost_path/boot.msg &"; |
229 |
|
|
230 |
# ubd2=$vhost_path/datafs/$vhost->{'datafs'} >> /dev/null"; # > $vhost_path/boot.msg"; |
# ubd2=$vhost_path/datafs/$vhost->{'datafs'} >> /dev/null"; # > $vhost_path/boot.msg"; |
231 |
|
|
232 |
|
#print $start_cmd; exit; |
233 |
|
|
234 |
askCmd("do it", $start_cmd, "starting \"$vhost_name\" on \"$ip\""); |
askCmd("do it", $start_cmd, "starting \"$vhost_name\" on \"$ip\""); |
235 |
unlock($vhost_name); |
unlock($vhost_name); |
236 |
|
|
238 |
|
|
239 |
print <<EOM; |
print <<EOM; |
240 |
Please note: |
Please note: |
241 |
Your linux called $vhost_name is running as $owner. |
Your linux called "$vhost_name" is running as "$owner". |
242 |
Since "screen" is used here, there are some issues you should know about: |
Since "screen" is used here, there are some issues you should know about: |
243 |
You can't use the normal "su" to switch to this user from a root shell, |
You can't use the normal "su" to switch to this user from a root shell, |
244 |
because the Terminal of this shell would still be owned by root. |
because the Terminal of this shell would still be owned by root. |