Tag Archives: configure

How to configure Proxy Settings for the Unix / Linux Console

You can use the following methods to configure your console to use a proxy server so that console based programs like wget could get connect to the internet through the proxy.

1 – Set the environment variable
# export http_proxy=http://DOMAIN\USERNAME:PASSWORD@SERVER:PORT/

In the above configuration you can ommit the DOMAIN\USERNAME:PASSWORD@ part if you are not using proxy authentication.

Note: If you get the following error when you try to use wget, you might have to pass the proxy authentication credentials to wget as arguments.

Connecting to SERVER:PORT... connected.
Proxy request sent, awaiting response... 407 Proxy Authentication Required
11:14:45 ERROR 407: Proxy Authentication Required.
1.1 – Passing proxy authentication credentials to wget as arguments
$ wget --proxy-user "DOMAIN\USERNAME" --proxy-passwd "PASSWORD" URL
2 – Configure the proxy settings in the .bashrc
If you want set the proxy for all the users you can do it in the system wide .bashrc file.

nano /etc/bash.bashrc#proxy settings

Note: The system wide .bashrc file may not be available in all Linux systems and only can be used if you are using the bash shell

2.1 – Having an alias for wget with proxy
If you don’t want to pass the proxy arguments to wget all the time, you create an alias for wget in the .bashrc file

alias wget 'wget --proxy-user "DOMAIN\USERNAME" --proxy-passwd "PASSWORD"'

Linux Install & configure Squid in three easy steps

  1. Squid configuration so that it will act as a transparent proxy


  2. Iptables configuration

    • Configure system as router
    • Forward all http requests to 3128 (DNAT)
  3. Run scripts and start squid service

First, Squid server installed (use up2date squid) and configured by adding following directives to file:
# vi /etc/squid/squid.conf

Modify or add following squid directives:

acl all src
acl manager proto cache_object
acl localhost src
acl to_localhost dst
acl SSL_ports port 443
acl Safe_ports port 80          # http
acl Safe_ports port 21          # ftp
acl Safe_ports port 443         # https
acl Safe_ports port 70          # gopher
acl Safe_ports port 210         # wais
acl Safe_ports port 1025-65535  # unregistered ports
acl Safe_ports port 280         # http-mgmt
acl Safe_ports port 488         # gss-http
acl Safe_ports port 591         # filemaker
acl Safe_ports port 777         # multiling http
http_access allow manager localhost
http_access deny manager
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports
http_access allow localhost
http_access allow all
icp_access allow all
http_port 3128
hierarchy_stoplist cgi-bin ?
access_log /var/log/squid/access.log squid
acl QUERY urlpath_regex cgi-bin ?
cache deny QUERY
refresh_pattern ^ftp:           1440    20%     10080
refresh_pattern ^gopher:        1440    0%      1440
refresh_pattern .               0       20%     4320
acl apache rep_header Server ^Apache
broken_vary_encoding allow apache
coredump_dir /var/spool/squid



  • acl all src  : Access control list, only allow LAN computers to use squid
  • http_access allow localhost: Squid access to LAN and localhost ACL only
  • http_access allow all: — same as above —

Here is the complete listing of squid.conf for your reference grep will remove all comments and sed will remove all empty lines:

# grep -v "^#" /etc/squid/squid.conf | sed -e '/^$/d'


Iptables configuration


Next, I had added following rules to forward all http requests (coming to port 80) to the Squid server port 3128 :
iptables -t nat -A PREROUTING -i eth1 -p tcp --dport 80 -j DNAT --to
iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 3128

How to configure a VMware ESX / ESXi host with a QLogic HBA to boot from SAN in a CLARiiON environment

How to configure a VMware ESX / ESXi host with a QLogic HBA to boot from SAN in a CLARiiON environment


This procedure explains how to configure the QLogic HBA to boot ESX/ESXi from SAN. The procedure involves enabling the QLogic HBA BIOS, enabling the selectable boot, and selecting the boot LUN.


1. While booting the server, press Ctrl+Q to enter the Fast!UTIL configuration utility.

2. Perform the appropriate action depending on the number of HBAs.

Option Description
One HBA If you have only one host bus adapter (HBA), the Fast!UTIL Options page appears. Skip to Step 3.
Multiple HBAs If you have more than one HBA, select the HBA manually.

1. In the Select Host Adapter page, use the arrow keys to position the cursor on the appropriate HBA.

2. Press Enter.

3. In the Fast!UTIL Options page, select Configuration Settings and press Enter.

4. In the Configuration Settings page, select Adapter Settings and press Enter.

5. Set the BIOS to search for SCSI devices.

a. In the Host Adapter Settings page, select Host Adapter BIOS.

b. Press Enter to toggle the value to Enabled.

c. Press Esc to exit.

6. Enable the selectable boot.

a. Select Selectable Boot Settings and press Enter.

b. In the Selectable Boot Settings page, select Selectable Boot.

c. Press Enter to toggle the value to Enabled.

7. Use the cursor keys to select the Boot Port Name entry in the list of storage processors (SPs) and press Enter to open the Select Fibre Channel Device screen.

8. Use the cursor keys to select the specific SP and press Enter.

If you are using an active-passive storage array, the selected SP must be on the preferred (active) path to the boot LUN. If you are not sure which SP is on the active path, use your storage array management software to find out. The target IDs are created by the BIOS and might change with each reboot.

9. Perform the appropriate action depending on the number of LUNs attached to the SP.

Option Description
One LUN The LUN is selected as the boot LUN. You do not need to enter the Select LUN screen.
Multiple LUNs Select LUN screen opens. Use the cursor to select the boot LUN, then press Enter.

To configure a CLARiiON array to serve as a boot device for a Solaris server, follow these steps:

Note: Check the EMC Support Matrix or E-Lab Navigator for the versions of Solaris and arrays that support using the array as a boot device.

1. Partition your LUN on your CLARiiON array so you have the slices of required sizes.

2. Run the newfs command to make a filesystem on the slices you need.

3. Make a mount point for the slice that you are going to copy to the LUN.

4. Mount the slice at the mount point.

5. Use the cd command to change your current directory to the mounted slice.

6. Run the following command to copy the slice to the array:

# ufsdump 0f – /dev/dsk/cxtxdxsx | ufsrestore rf –

Where x= controller,target,LUN, slice where the OS currently resides.

7. Run the command to copy a boot block to the LUN:

# /usr/sbin/installboot /usr/platform/sun4u/lib/fs/ufs/bootblk /dev/rdsk/cxtxdxsx

Where x= controller, target, LUN, and slice of array LUN.

8. Change /etc/vfstab to the new slices.

9. If ATF is to be part of this configuration, you must install it after setting up the boot partition.