Postagens

Mostrando postagens de junho, 2020

How to Enable SSH on Cisco Switch, Router

1) Generate the RSA Keys      myswitch(config)# crypto key generate rsa             The name for the keys will be: myswitch.mydomain.com          How many bits in the modulus [512]: 1024      % Generating 1024 bit RSA keys, keys will be non-exportable...[OK] 2) Setup the Line VTY configurations     # line vty 0 4      (config-line)# transport input ssh     (config-line)# login local     (config-line)# password 7     (config-line)# exit 3) Setup the Console configuration      # line console 0      (config-line)# logging synchronous      (config-line)# login local 4) Verify SSH access      myswitch# sh ip ssh           SSH Enabled - version 1.99           Authentication timeout: 120 secs; Authentication retries: 3 That's it

How to force reinstall software assigned via GPO when it was manually uninstalled

How to force reinstall software assigned via GPO when it was manually uninstalled On the computer, go to HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Group Policy\AppMgmt. Identify the software by looking at the “Deployment Name” value. Delete the key of the software you need to reinstall. Reboot and check if the software is reinstall.

How to change dhcp/static IP on Ubuntu 18.04

For DHCP edit file /etc/netplan/50-cloud-init.yaml and change to: network:     ethernets:         eth0:             addresses: []             dhcp4: true             optional: true     version: 2 For a static IP edit file /etc/netplan/50-cloud-init.yaml and change to: network:     ethernets:         eth0:             addresses:             - 192.168.1.2/24             gateway4: 192.168.1.1             nameservers:                 addresses:                 - 1.1.1.1                 search:                 - domain.local             optional: true     version: 2 $ sudo netplan apply $ sudo netplan try That's it

How to configure nested virtualization Hyper-V VM

$VMName = 'VM' Set-VMProcessor -VMName $VMName -ExposeVirtualizationExtensions $true

How to change hostname on Ubuntu 18.04

$ sudo hostnamectl set-hostname <newname> Change "preserve_hostname:" false to true on /etc/cloud/cloud.cfg $ sudo vi /etc/cloud/cloud.cfg Add newname to /etc/hosts $ sudo vi /etc/hosts 127.0.0.1 <newname> $ sudo reboot

How to resizing the Linux Root Partition

In this example i use the Ubuntu Linux on Hyper-V VM Gen2 and default LVM partitioning. Check your partitioning with lsblk. Now check the mount point with df -h. Resize disk on Hyper-V and  if you cannot view the total size you need reboot or rescan disk. # echo 1 > /sys/block/sda/device/rescan # parted GNU Parted 3.1 Using /dev/sda Welcome to GNU Parted! Type 'help' to view a list of commands. (parted) p Error: The backup GPT table is not at the end of the disk, as it should be.  This might mean that another operating system believes the disk is smaller.  Fix, by moving the backup to the end (and removing the old backup)? Fix/Ignore/Cancel? Fix Warning: Not all of the space available to /dev/sda appears to be used, you can fix the GPT to use all of the space (an extra 20971520 blocks) or continue with the current setting? Fix/Ignore? Fix Model: Msft Virtual Disk (scsi) Disk /dev/sda: 31.5GB Sector size (logical/physical): 512B/4096B Partition Table: gpt Disk Flags: Number