feat: add DNS setup blueprint and infrastructure automation scripts
This commit is contained in:
31
scripts/test_racadm_queries.py
Normal file
31
scripts/test_racadm_queries.py
Normal file
@@ -0,0 +1,31 @@
|
||||
import paramiko
|
||||
import time
|
||||
|
||||
c = paramiko.SSHClient()
|
||||
c.set_missing_host_key_policy(paramiko.AutoAddPolicy())
|
||||
c.connect('140.44.44.121', username='root', password='Katzir476!', timeout=10)
|
||||
|
||||
chan = c.invoke_shell()
|
||||
time.sleep(2)
|
||||
if chan.recv_ready():
|
||||
chan.recv(4096)
|
||||
|
||||
commands = [
|
||||
"racadm get bios.SysProfileSettings.SysProfile",
|
||||
"racadm get bios.ProcSettings.ProcVirtualization",
|
||||
"racadm get bios.IntegratedDevices.SriovGlobalEnable",
|
||||
"racadm raid get controllers",
|
||||
"racadm raid get pdisks"
|
||||
]
|
||||
|
||||
for cmd in commands:
|
||||
chan.send(cmd + "\r\n")
|
||||
time.sleep(2)
|
||||
resp = ""
|
||||
while chan.recv_ready():
|
||||
resp += chan.recv(4096).decode('utf-8', errors='ignore')
|
||||
time.sleep(0.5)
|
||||
print(f"=== {cmd} ===")
|
||||
print(resp.strip())
|
||||
|
||||
c.close()
|
||||
Reference in New Issue
Block a user