Tuesday, October 6, 2026

Sequence to connect to iSCSI Volume from Ubuntu 20.x Server

Connect to iSCSI Volume from Ubuntu 20.04.  Maybe this will help.

Step 1. Install open-iscsi

sudo apt update
sudo apt install open-iscsi
Step 2. Configure initiatorname.conf

We need to edit the initiatorname.conf file located in /etc/iscsi directory.

sudo nano /etc/iscsi/initiatorname.conf
Now enter the initiator name of the iSCSI target into this file. 

In my example, i'm creating a SCSI drive on an Iomega ix4-200d device

For example, in my case, it would be:

InitiatorName=iqn.1992-04.com.emc:storage.ix4-200d-TILRBJ.media


Now save and close the file.



Step 3. Configure iscsid.conf

Now we need to edit the default configuration file


sudo nano /etc/iscsi/iscsid.conf

In this config file, we need to edit some sections to match our iSCSI target server. If your iSCSI target discovery authentication mode set to None, you can leave this config untouched. It will work out of the box. If your iSCSI target server use CHAP, then you need to edit the following


Find and uncomment the following line


node.session.auth.authmethod = CHAP
node.session.auth.username = username
node.session.auth.password = password


Enter the CHAP credentials, username, and password you created on the iSCSI target server. Close and save the file. Now restart the service

sudo systemctl restart iscsid open-iscsi

Step 3. Connect to the iSCSI Target

Discover the iSCSI Target

First, we will need to discover the iSCSI target. On the Terminal, use this command to discover the target

Change the IP address with your actual iSCSI Target server IP.

sudo iscsiadm -m discovery -t sendtargets -p 192.168.100.100

Note down the output as we will need to use it for the next step below. This is important if we have multiple targets in the server like above.


Connect to the iSCSI Target Volume


Now we can login to the target with this command.


sudo iscsiadm --mode node --targetname iqn.2005-10.org.freenas.ctl:iscsi01 --portal 192.168.100.100 --login

Output:


dhani@dhani-Ubuntu:~$ sudo iscsiadm --mode node --targetname iqn.2005-10.org.freenas.ctl:iscsi01 --portal 192.168.100.100 --login
Logging in to iface: default, target: iqn.2005-10.org.freenas.ctl:iscsi01, portal: 192.168.100.100,3260
Login to [iface: default, target: iqn.2005-10.org.freenas.ctl:iscsi01, portal: 192.168.100.100,3260] successful.

The command above will only connect to the iscsi01 target only. If you have multiple targets on the server, and you want to login into them all, you can use this command

sudo iscsiadm -m node -l

To log out from all the targets, use this


sudo iscsiadm -m node -u

Done.


Now let’s check our block disk using fdisk command


sudo fdisk -l

As you can see my iSCSI disk is recognized as /dev/sdb.


Step 4. Format the iSCSI Disk

So now we’ve connected to the iSCSI disk. We can then format or create a partition on the iSCSI Disk, just like a local disk. In the following example, I will create a new partition and format the disk to ext4 file system.

---------------
Was having problems creating partitions larger that 2TB so used 
sudo gdisk /dev/sdb

instead and that allowed me to create larger parititons.
---------------


sudo fdisk /dev/sdb

Now type n to create a new partition.


Command (m for help): n
Partition type
p primary (0 primary, 0 extended, 4 free)
e extended (container for logical partitions)
Select (default p):

Type p to create primary partition and then type 1 to create one partition. You can change this to two for example, if you want to create two partitions.


Select (default p): p
Partition number (1-4, default 1): 1
First sector (256-13107203, default 256):
Last sector, +/-sectors or +/-size{K,M,G,T,P} (256-13107203, default 13107203):

Created a new partition 1 of type ‘Linux’ and of size 50 GiB.


Type w to write the change. Next, let’s check using fdisk


sudo fdisk -l

As you can see, now I have a new partition called /dev/sdb1.


Format the partition to ext4


Next, I will format this partition to ext4 file system.


sudo mkfs.ext4 /dev/sdb1
dhani@dhani-Ubuntu:~/Downloads$ sudo sudo mkfs.ext4 /dev/sdb1
mke2fs 1.45.5 (07-Jan-2020)
Discarding device blocks: done
Creating filesystem with 13106948 4k blocks and 3276800 inodes
Filesystem UUID: aa38ff4c-9d84-49c2-a1d9-9c368319f95f
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424
Allocating group tables: done
Writing inode tables: done
Creating journal (65536 blocks): done
Writing superblocks and filesystem accounting information: done

Mount the partition


sudo mkdir /mnt/iscsi_disk
mount /dev/sdb1 /mnt/iscsi-disk

Wednesday, September 23, 2026

Helpful Windows IT commands

A short cut to open CMD or POWERSHELL as administrator

A short cut to open a CMD prompt or POWERSHELL prompt as administrator, is to 'search' for either CMD or Powershell and then press CTRL SHIFT ENTER which will open it as administrator


OR as PowerShell



Zero out your harddrive

This will write out zero's to the free space on your Windows 11 box.  This could take a couple of hours but will run in the background.

cipher /w:c




Automatically download and update all my applicable applications on my computer

winget upgrade -all


It will start to do updates of apps on your machine.  Very useful.


Scan for problems on windows 11 and attempt automatic repair of discovered issues.  

sfc /scannow


Another tool to look for possible issues.  This looks for specific windows updates and images and makes sure they are working

dism /online /cleanup-image /restorehealth

Super detailed battery report of your laptop

powercfg /batteryreport


Show all the MAC addresses on your machine

getmac


Show all the apps installed on your computer

wmic product get name


Anyone forget about this one?  Cruise a machine that you have access to on your network
net use \\NameOfComputer\c$

pathping

Thursday, September 17, 2026

Factory Reset VTech VCS754

This has been a fantastic phone.  Its best feature is that it works as a PC based speaker phone right to your computer via USB.  It's awesome.

Factory Resetting VTech VCS754
To perform a factory reset on the VTech ErisStation VCS754, follow these steps:

  1. Unplug the data network cable from the VCS754 transformer.
  2. Unplug the power adapter from the VCS754 and wait for 2 minutes.
  3. Re-plug the power adapter to power up the VCS754 with only the power cable.
  4. Press the MENU button.
  5. Press the keys: 0, 6, #.
  6. Scroll to "Factory default" in the menu.
  7. Press "SELECT" to reboot the VCS754

Asterisk FreeBPX fail2ban whitelist and status

Here's some asterisk fail2ban info 

List Banned IPs in Fail2Ban

Fail2Ban stores a list of all the IPs currently banned from connecting to your server. Run the following command to see all active jails on your server:

sudo fail2ban-client status

The one you are probably interested in is "asterisk-iptables"

sudo fail2ban-client status asterisk-iptables



Here you'll see that 192.168.0.101 is banned.  This was a phone that I couldn't make register.

Unban Specific IP in Fail2Ban

This command will let you unban an IP.  In my example i'm going to unban 192.168.0.101 from the asterisk-iptables ban.

sudo fail2ban-client set asterisk-iptables unbanip 192.168.0.101


Now you see that the "banned IP list" is blank.

Whitelist Specific IP in Fail2Ban

sudo nano -l /etc/fail2ban/jail.local
  1. look for ignoreIP.  There should be one in there already of 127.0.0.1/8
  2. Add a space and then add the additional IP(s) that you want
ignoreip = 127.0.0.1/8 192.168.0.101 192.168.0.102
  1. Save the file and then reload Fail2Ban.
sudo systemctl reload fail2ban
You can check the fail2ban status
sudo systemctl status fail2ban