npm
--registry=https://registry.npm.taobao.org
npm install -g electron --unsafe-perm=true --allow-root
--unsafe-perm=true即可
export http_proxy=http://127.0.0.1:8087
--registry=https://registry.npm.taobao.org
npm install -g electron --unsafe-perm=true --allow-root
--unsafe-perm=true即可
export http_proxy=http://127.0.0.1:8087
source: http://wiki.xfce.org/zh-cn/howto/install_new_themes
xfce有5种主题
主题下载:
NetBIOS协议节点类型
这里有一个术语叫nodedesignation,中文意思我认为就是节点指定,它主要用来表明某计算机节点解析计算机名称及地址的方法。每个NetBIOS计算机都有一种节点类型,共有四种节点类型对应于四种解析方法:
B节点——只使用广播方法。该类型的节点在本地子网上使用广播消息来发现位于同一子网中的计算机。
广播节点( B节点)只通过广播数据报来解析LAN子网中计算机名和地址,即它的有效范围只是它所在的子网。其工作方式是:客户机发送一条广播消息到其所在的局域子网上,这条消息包含有要查找的计算机的IP地址和其本身的MAC地址。由于使用广播方式,则该网上的所有计算机都会接收到,如果该数据报中所要求的地址的计算机存在,则它就会根据包含在此数据报中的发出该消息的计算机的MAC地址作出回应。这样,计算机就会把经常用到的MAC地址缓存起来,通过这些地址实现与远程计算机的直接通信。
:::: code-group
::: code-group-item hash.ps1:active
function Test-FileHash {
param(
# FilePath
[string]$Path,
# Algorithm
[string]$Algorithm = "SHA256",
# Compare Hash
[string]$Hash
)
begin {
$file = Get-Item $Path
if ($Hash) { break }
$parent = $file.Directory
if ('hash.json' -notin ($parent.GetFiles().Name)) { break }
$fileList = Get-Content "hash.json" | ConvertFrom-Json
if ($file.Name -notin $fileList.FileName) { break }
$record = $fileList | Where-Object FileName -eq $file.Name
$Algorithm = $record.Algorithm
$Hash = $record.Hash
}
process {
$fileHash = Get-FileHash $Path -Algorithm $Algorithm
$result = @{
FileName = $Path
OriChecksum = $Hash
FileHash = $fileHash.Hash
Verify = $Hash.ToUpper() -eq $fileHash.Hash
}
}
end {
return $result
}
}
function Test-FilesHash {
$fileList = Get-Content "hash.json" | ConvertFrom-Json
$result = @()
$fileList | ForEach-Object {
if (Test-Path $_.FileName) {
$result += (Test-FileHash $_.FileName)
}
}
$result | Format-Table
}
Test-FilesHash
# force stop
ls -l /run/lock/qemu-server
rm -f /run/lock/qemu-server/lock-101.conf
qm unlock 101
qm stop 101
qm status 101
# normal vers
qm shutdown <VMID>
qm reboot <VMID>
# reset
qm reset <VMID>
# import img
# upload to /var/lib/vz/images
cd /var/lib/vz/images
qm importdisk 100 xxx.img local-lvm
# import qcow2
qm importdisk 100 xxx.qcow2 local-lvm
# upload ISO
# upload to /var/lib/vz/template/iso
# determine volumes
ls /dev/mapper/
# convert disk to qcow2 format
qemu-img convert -O qcow2 /dev/vg-ssd/vm-115-disk-0 /data/xxx.qcow2
# about iscsi
pvesm remove nas
pvesm add iscsi nas --portal 192.168.1.1 --target iqn.2004-04.com.qnap:ts-563:iscsi.pve.1b5a7c
iscsiadm -m session
iscsiadm -m node -p 192.168.1.1 -T iqn.2004-04.com.qnap:ts-563:iscsi.pve.1b5a7c -l
systemctl restart pvestatd
lvcreate --thin -L 80G -n lv-nas vg-nas
# others
du -hl
/var/lib/docker/containers
# 通知底层设备释放空间
# 需要vdisk开启discard
fstrim -av
apt install qemu-utils
qemu-img convert -f raw -O vmdk image.img image.vmdk
example:
ethernet4.pciSlotNumber = "1216"
Bus:Dev.Func
FFF.BBBBB.DDDDD
001.00110.00000 [1216 = 0x4C0]
If BBBBB is 00000, the device is on the Primary PCI bus.
If BBBBB is non-zero, the device is on a Secondary PCI bus.