mirror of
https://github.com/unraid/webgui.git
synced 2026-04-22 18:19:14 -05:00
Merge pull request #427 from bergware/master
VM manager: remove and rebuild USB controllers
This commit is contained in:
@@ -1116,6 +1116,11 @@
|
||||
if ($p2['bus'] && $p2['slot'] && $p2['function'] && $p2['bus']==$pci['bus'] && $p2['slot']==$pci['slot'] && $p2['function']==$function) unset($old['devices']['hostdev'][$k]);
|
||||
}
|
||||
}
|
||||
// remove and rebuild usb controllers
|
||||
$devices = $old['devices']['controller'];
|
||||
foreach ($devices as $key => $controller) {
|
||||
if ($controller['@attributes']['type']=='usb') unset($old['devices']['controller'][$key]);
|
||||
}
|
||||
// preserve existing disk driver settings
|
||||
foreach ($new['devices']['disk'] as $key => $disk) {
|
||||
$source = $disk['source']['@attributes']['file'];
|
||||
|
||||
@@ -23,6 +23,7 @@ if ($newarray) {
|
||||
@unlink('/boot/config/smart-one.cfg');
|
||||
@unlink('/boot/config/smart-all.cfg');
|
||||
@unlink('/boot/config/plugins/dynamix/monitor.ini');
|
||||
@unlink('/var/tmp/cache_log.tmp');
|
||||
}
|
||||
?>
|
||||
<style>
|
||||
|
||||
Reference in New Issue
Block a user