Jul 13
2024
Create a new VM in the web interface (leave other settings as default)
copy VM disk to proxmox (ex. using terminal) and import it to newly created VM machine
qm importdisk machine_id_number /var/lib/vz/images/file.qcow local-zfs
qm rescan
Go to your new created VM in the proxmox web interface.
Go to the Hardware section of the newly created VM in the Proxmox web interface
Look for the Unused Disk and select it.
Then you have to add the disk by clicking on Edit on the top.
Jul 13
2024
On all mounting points
dd if=/dev/zero of=/nul;sync;sync;sync;rm -f /nul;sync
qemu-img convert -O qcow2 -c disk1.qcow disk1.new.qcow
Jun 28
2024
upower -i $(upower -e | grep '_AC') | grep "online"
Jun 20
2024
mysqlcheck -u root -p --auto-repair --check --all-databases
Jan 14
2024
Add to /etc/unbound/unbound.conf
server:
interface: 0.0.0.0
Jan 14
2024
split-window -h: Ctrl+b %
split-window -v: Ctrl+b ”
Sep 14
2023
Linux Mint
install chromium and
mv /usr/lib/x86_64-linux-gnu/opera/libffmpeg.so /usr/lib/x86_64-linux-gnu/opera/libffmpeg.so.orig
ln -s /usr/lib/chromium/libffmpeg.so /usr/lib/x86_64-linux-gnu/opera/
Linux Arch
install electron37 and
mv /usr/lib64/opera/libffmpeg.so /usr/lib64/opera/libffmpeg.so.orig
ln -s /usr/lib/electron37/libffmpeg.so /usr/lib64/opera/
Sep 9
2023
Powershell
Install-Module dbatools
Import-Module dbatools
Set-DbatoolsInsecureConnection -SessionOnly
Restore-DbaDatabase -SqlInstance SERVER-NAME\INSTANCE-NAME -Path 'C:\PATH-TO-BACKUPS'
Sep 2
2023
lists logins and incorrect SIDs
USE <platnik_db>
GO
EXEC sp_change_users_login 'Report'
GO
Then start SQL
USE <platnik_db>
GO
EXEC sp_change_users_login 'Auto_Fix','<user_name>',NULL, '<password>'
GO
Sep 2
2023
drop databases query
USE master;
Go
SELECT 'DROP DATABASE ['+ name + ']'
FROM sys.databases WHERE name like 'PREFIX%';
GO