Travel

Categories

Use photoshop layer to fix overexposure, underexposure and enhance contrast

1. Fix overexposure

  • Press ctrl-J to duplicate the background image to new layer
  • Choose “Multiply” layer mode

2. Fix underexposure

  • Choose “Screen” layer mode

3. Enhance contrast

  • Choose “Soft light” layer mode

How to avoid Backscatter in Sendmail

Taken from http://elqui.dcsc.utfsm.cl/util/email/backscatter.html

Your MX servers should reject email for unknown users at the SMTP initial transaction and NOT forward them to internal SMTP servers without a “user check”.

  • Step1: In MX SERVER, add these 4 lines to your “.mc” file in the right place..
    FEATURE(access_db, hash -T<TMPF> /etc/mail/access)dnl
    FEATURE(`blacklist_recipients’)dnl
    define(`VIRTUSER_TABLE’, `hash -o /etc/mail/virtusertable’)dnl
    VIRTUSER_DOMAIN_FILE(`/etc/mail/virtuserdomain’)dnl

  • Step2: In MX SERVER, put YOUR internal valid domains in /etc/mail/virtuserdomain
    #
    example.com
    my.org

  • Step3: In MX SERVER, add these lines to your “access” file (/etc/mail/access):
    ——————-insert into access file—————————–
    # list of internal domains that have their own servers
    # and you do not serve them. Your server only receives email
    # from them.
    # equal to “internal domains that you receive email via MX”
    From:marketing.my.org         OK
    From:marketing.example.com    OK

    ######################
    # Reject Forgery – Not requiered for Backscattering
    ######################
    # FOR TEST USE: /usr/lib/sendmail -bt
    # check_mail <valid.user@example.com> –> ACCESS DENIED
    From:example.com      REJECT
    # check_mail <valid.user@my.org> –> ACCESS DENIED
    From:my.org           REJECT

    ######################
    ## Reject Backscatter….
    # reject unknown recipients, because SPAMMERS
    # use this to spam other domains through bounces
    # messages (user unknown).
    #
    ##############################################
    # general rejection strings
    To:example.com     error:5.1.1:”550 User unknown”
    To:my.org          error:5.1.1:”550 User unknown”
    #
    ################################################
    # List ALL valid internal EMAIL addresses
    # If not listed here, sender server will get a “550 User unknown”
    # you should use a shell script to help you build
    # this list each time you create a user.
    #
    To:john.doe@example.com    RELAY
    To:jane.joe@my.org         RELAY
    To:postmaster@example.com  RELAY
    etc…
    ——————-end inserto into access—————————–
  • Step4: In MX SERVER, regenerate your “sendmail.cf” and re-makemap your “access” database

  • Step5: In MX SERVER, TEST the configuration using an external IP address (in this example 200.89.70.8 mx.uchile.cl):$ /usr/lib/sendmail -bt -d21.4
    .D{client_addr}200.89.70.8
    .D{client_name}mx.uchile.cl

    check_rcpt <john.doe@example.com>
    # should produce a —> RELAY

    check_rcpt <user.notexist@example.com>
    # should produce a —> “550 User unknown

2010香港花卉展

行完花卉展就去咗喜來登食tea Buffet

IMG_2828IMG_2831

大埔海濱公園 – 三月之花

Cheap external RAID storage based on eSATA

Sourcing cheap external RAID storage based on eSATA

1. 5 bay 3.5″ SATA external RAID stoarge ($1399)

http://alris.com.hk/?p=427&lang=en

2. Still sourcing a fast SATA RAID controller with RAID5  and eSATA connection

Installation of VMware ESXi 4 on ASUS P6T machine

The steps are easy. Just download the VMware esxi4 update 1 ISO and install on an USB thumb drive attached on the machine. The only stuff need to twist is the detection of the onboard Realtek 8111C NIC which the original esxi4 doesn’t support.

Following the instructions from http://www.vm-help.com/esx40i/customize_oem_tgz.php, I replaced the /bootbank/oem.tgz with the Realtek 8168 / 8111 NICs driver oem.tgz. The detection of the on board Realtek 8111C NIC works without problem after reboot. However, one glitch which I can’t solve is that the 8111 NIC can’t be configured to contain the management network VLAN under a trunk port. ping will work but the vsphere client connection never got any response. However, the NIC works without problem as a trunk port if it is configured to be used by a guest. Anyway, it is a minor problem and my redundant VMware ESXI 4 server is up and running without problem on a box with ASUS P6T MB+Intel Core i7 920

很XX的一次打邊爐

尋日同呀超,Maggie去大埔鴻星打邊爐, 聽個侍應老點, 叫咗個雜錦鍋, 一上嚟, 即刻知道賴嘢喇. 大佬呀, 我平時都唔食內臟, 佢個雜錦鍋有一半都係D血淋淋嘅內臟, 見到都想嘔呀, 對住佢真係唔會有食慾. 好辛苦咁食完, 拿拿臨走咗去食甜品補數.

SNC00092

很核突的雜錦鍋!!

SNC00094

晚餐主菜就係呢個甜品

Force duplex printing in Mac Snow leopard

1. Add the duplex printer first

2. edit /private/etc/cups/ppd/hp8150.ppd

3. Search “Duplex None” and replace the fragment from

*Duplex None/Off (1-Sided): ”
<</Duplex false>> setpagedevice”

To

*Duplex None/Off (1-Sided): ”
<</Duplex true /Tumble false>> setpagedevice”

My Canon EOS 400D release count

At this writing it is 12320.

中大三月杜鵑花開時

Taken using a Tamron 90mm macro