2012-12-10

How to control access based upon IP(s) with IIS


How to control access based upon IP(s) with IIS
  • Install [IP and Domain Restrictions]
    1. Run Server Manager and open [Roles > Web Server (IIS)]
    2. Scroll down to [Role Services] at [Summary]
    3. Click [Add Role Services] on right pane
    4. Check [IP and Domain Restrictions] on [Role Services > Web Server > Security]
    5. Click [Install]
  • Block clients by IP
    1. Run IIS Manager and select a specific site or folder
    2. Open [IPv4 Address and Domain Restrictions]
    3. Open [Edit Feature Settings] to set an option for DENY or ALLOW from all
    4. Open [Add Allow/Deny Entry] to add IP or IP range

2012-10-09

DoEvent for WPF

System.Windows.Application.Current.Dispatcher.Invoke
(
 DispatcherPriority.Background,
 new System.Threading.ThreadStart
 (
  delegate { }
 )
);

2012-09-28

How to fix log4j.dtd XML problem in eclipse

Problem
The file cannot be validated as the XML definition \path\to\workspace\java.shop\src\test\resources\log4j.dtd (The system cannot find the file specified)" that is specified as describing the syntax of the file cannot be located.

Reason
Eclipse cannot find the log4j.dtd for validation.

Solution
Open Preference (Window > Preferences) and Select XML>XML Catalog
Click [Add...] and insert the following
Location: jar:file:C:\USR\eclipse\plugins\org.apache.log4j_1.2.15.v201012070815.jar!/org/apache/log4j/xml/log4j.dtd
Key Type: Public ID
Key: -//APACHE//DTD LOG4J 1.2//EN


2012-09-23

Share Windows desktop with Linux

  1. Download and Install VirtualBox - https://www.virtualbox.org/wiki/Downloads
  2. Install Linux in VirtualBox and GuestEdition on Linux
  3. Go to Seamless mode View > Switch to Seamless mode
  4. Combined desktop - Windows 8 and Linux

2012-09-22

How to setup IssueTracker GIT PHP JSP for PHPEclipse


Download
xampp-win32-1.8.0-VC9-installer.exe :: http://www.apachefriends.org/en/xampp-windows.html
ruby-1.9.3-p125-i386-mingw32.7z :: http://rubyinstaller.org/downloads/ <== Do not use p194 because of bug
DevKit-tdm-32-4.5.2-20111229-1559-sfx.exe :: http://rubyinstaller.org/downloads/
mysql-connector-c-noinstall-6.0.2-win32.zip :: http://dev.mysql.com/downloads/connector/c/
redmine-2.1.0.zip :: http://rubyforge.org/frs/?group_id=1850
PortableGit-1.7.11-preview20120710.7z :: http://code.google.com/p/msysgit/

# Do not download the belows if you have a 32bit Windows box
apache-tomcat-7.0.30-windows-x64.zip :: http://tomcat.apache.org/
mysql-5.5.27-winx64.zip :: http://www.mysql.com/downloads/mysql/

Install XAMPP into C:\usr
Extract others into C:\usr
C:\usr\apache-tomcat-7.0.30\
C:\usr\mysql-5.5.27-winx64\
C:\usr\ruby-1.9.3-p194-i386-mingw32
C:\usr\DevKit-tdm-32-4.5.2-20111229-1559-sfx
C:\usr\mysql-connector-c-noinstall-6.0.2-win32
C:\usr\redmine-2.1.0
C:\usr\Git-1.7.11
Make symbolic link as Administrator
CMD> cd C:\usr
CMD> mklink /D ruby C:\usr\ruby-1.9.3-p194-i386-mingw32
CMD> mklink /D devkit C:\usr\DevKit-tdm-32-4.5.2-20111229-1559-sfx
CMD> mklink /D mysql-connector c:\usr\mysql-connector-c-noinstall-6.0.2-win32
CMD> mklink /D redmine C:\usr\redmine-2.1.0
CMD> mklink /D git C:\usr\Git-1.7.11
CMD> cd C:\usr\ruby\bin
CMD> mklink libmysql.dll C:\usr\mysql-connector\lib\libmysql.dll
## Skip if you have a 32bit Windows box
CMD> cd C:\usr
CMD> ren(or remove) tomcat tomcat7-32bit
CMD> ren(or remove) mysql mysql-5.5.25-winx86
CMD> mklink /D tomcat apache-tomcat-7.0.30
CMD> mklink /D mysql mysql-5.5.27-winx64
CMD> copy mysql-5.5.25-winx86\mysql_installservice.bat mysql
CMD> copy mysql-5.5.25-winx86\mysql_uninstallservice.bat mysql
CMD> copy mysql-5.5.25-winx86\mysql_resetroot.bat mysql
## Move mysql data directory to D drive : you can skip this
CMD> cd C:\usr\mysql-5.5.25-winx86
CMD> mkdir "D:\MySQL Data"
CMD> xcopy /S data "D:\MySQL Data"
CMD> cd C:\usr\mysql   <== make sure 64bit mysql(mysql-5.5.25-winx86)
CMD> ren(or remove) data data.org
CMD> mklink /D data "D:\MySQL Data"
Setup DevKit
Add C:\usr\ruby\bin into PATH
CMD> cd C:\usr\devkit
CMD> ruby dk.rb init
CMD> ruby dk.rb review <== Add "- C:/usr/ruby" into config.yml manually when init failed
CMD> ruby dk.rb install
Create database
CMD> cd C:\usr\mysql\bin
CMD> msyql -u root -p
mysql> create database redmine character set utf8;
mysql> grant all privileges on redmine.* to 'redmine'@'localhost' identified by 'PASSWORD';
Edit C:\usr\redmine\config\database.yml
production:
  adapter: mysql2
  database: redmine
  host: 127.0.0.1 <== In my case, localhost didn't work.
  username: redmine
  password: PASSWORD
Install redmine
Extract redmine into c:\usr\redmine-2.1.0
Add a line into C:\usr\redmine\Gemfile
gem "thin"
Install redmine
CMD> cd C:\usr\redmine
CMD> gem install bundler
CMD> bundle install --without development test rmagick  postgresql sqlite
CMD> set RAILS_ENV=production
CMD> rake generate_secret_token
CMD> rake db:migrate
CMD> rake redmine:load_default_data
Add to end of C:\usr\redmine\config\environment.rb
Redmine::Utils::relative_url_root = "/redmine"
Test
CMD> cd C:\usr\redmine
CMD> thin start -e production
Go to http://localhost:3000/redmine with your web browser, and login admin/admin

Configuration Redmine
Edit C:\usr\redmine\config\configuration.yml
set email in section default
set attachments_storage_path: C:/usr/redmine/files
set scm_git_command: C:\usr\git\cmd\git.exe
Run as a windows service
CMD> gem install win32-service
Save as C:\usr\redmine\service_install.rb
require 'rubygems'
require 'win32/service'

include Win32

SERVICE_NAME = 'Redmine'

# Create a new service
Service.create({
  :service_name       => SERVICE_NAME,
  :service_type       => Service::WIN32_OWN_PROCESS,
  :description        => 'Redmine on Thin as Windows Service',
  :start_type         => Service::AUTO_START,
  :error_control      => Service::ERROR_NORMAL,
  :binary_path_name   => 'c:\usr\Ruby\bin\ruby.exe -C C:\usr\redmine service.rb',
  :load_order_group   => 'Network',
  :dependencies       => ['W32Time','Schedule'],
  :display_name       => SERVICE_NAME
})
Save as C:\usr\redmine\servce.rb
REDMINE_DIR = 'C:\usr\redmine'
LOG_FILE = "#{REDMINE_DIR}\\log\\service.log"

begin
  require 'win32/daemon'
  include Win32

  class RedmineService < Daemon

    def service_init
      File.open(LOG_FILE, 'a'){ |f| f.puts "Initializing service #{Time.now}" }

      @server_pid = Process.spawn 'C:\usr\ruby\bin\ruby C:\usr\ruby\bin\thin start -p 3001 -e production --prefix /redmine', :chdir => REDMINE_DIR, :err => [LOG_FILE, 'a']
    end

    def service_main
      File.open(LOG_FILE, 'a'){ |f| f.puts "Service is running #{Time.now} with pid #{@server_pid}" }
      while running?
        sleep 10
      end
    end

    def service_stop
      File.open(LOG_FILE, 'a'){ |f| f.puts "Stopping server thread #{Time.now}" }
      system "taskkill /PID #{@server_pid} /T /F"
      Process.waitall
      File.open(LOG_FILE, 'a'){ |f| f.puts "Service stopped #{Time.now}" }
      exit!
    end
  end

  RedmineService.mainloop

rescue Exception => e
  File.open(LOG_FILE,'a+'){ |f| f.puts " ***Daemon failure #{Time.now} exception=#{e.inspect}\n#{e.backtrace.join($/)}" }
  raise
end
Install service and run it as Administrator
CMD> cd C:\usr\redmine
CMD> ruby service_install.rb
CMD> net start Redmine
# Check if Redmine runs and see logs at C:\usr\redmine\log\service.log
# See http://localhost:3001/redmine/
Attach to Apache
Add to end of C:\usr\apache\conf\httpd.conf
Include "conf/extra/httpd-proxy-redmine.conf"
Save as C:\usr\apache\conf\extra\httpd-proxy-redmine.conf
<IfModule !mod_proxy.c>
    LoadModule proxy_module modules/mod_proxy.so
</IfModule>
<IfModule !mod_proxy_http.c>
    LoadModule proxy_http_module modules/mod_proxy_http.so
</IfModule>

<IfModule proxy_module>
  <IfModule proxy_http_module>

  ProxyRequests Off
  ProxyPreserveHost On

  <Proxy *>
      Order deny,allow
      Allow from all
  </Proxy>

  ProxyPass /redmine http://127.0.0.1:3001/redmine/
  ProxyPassReverse /redmine http://127.0.0.1:3001/redmine/
  </IfModule>
</IfModule>
See http://localhost/redmine/

2012-09-20

How to run IIS and Apache on the same server

IIS binds all IPs on the server using http.sys.

Sample configuration
IIS on 192.168.0.10:80
Apache on 192.168.0.20:80
  1. For IIS
    • Run netsh on Windows 2008 server,
    • C:\>netsh
      netsh> http add iplisten ipaddress=192.168.0.10
      
      IP address successfully added
      
      netsh> http show iplisten
      
      IP addresses present in the IP listen list:
      -------------------------------------------
      192.168.0.10
      
      netsh> exit
      
    • Download and Run httpcfg on Windows 2003 server,
    • http://www.microsoft.com/en-us/download/details.aspx?displaylang=en&id=15326
      C:\> httpcfg.exe set iplisten -i 192.168.0.10
      C:\> net stop http
      C:\> net start http
      

  2. For Apache Modify httpd.conf
  3. Listen 192.168.0.20:80
    
  4. Result
    • You can see the Welcome screen by IIS with http://192.168.0.10/
    • Also, you have the response from Apache with http://192.168.0.20/

2012-08-21

DefFactory.dat cannot be opened

I faced a problem while installing Visual Studio 2010.

The data file
'C:\Users\julien\AppData\Local\Temp\SIT37791.tmp\DefFactory.dat'
cannot be opened.

Solution :
Copy the following lines, and paste them into the above file.


[Version]
Signature = "$Windows NT$"
Provider="Microsoft Visual Studio 2010 Professional Edition - ENU"
Version=800.100.00
NullString=Null String
Lang=1033

[Scenario List]
vsscenario.dll

[Scenario Factory Information]
Default Scenario=11E4C8F3-425E-43b9-B689-8BFDF03342E2

2012-08-10

How to hide user accounts on Windows 7/Vista logon

I found user accounts on Windows logon after setting up the GIT service on my Windows box.
However, they are important to run GIT. So, I want to hide them.


  1. Run [regedit]
  2. Find the following key with [regedit]
    HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Winlogon
  3. Add a new key under [Winlogon]
    1. Click right button on [Winlogon]
    2. Click [New]
    3. Click [Key]
    4. Type [SpecialAccounts]
  4. Add one more new key under [SpecialAccounts]
    1. Click right button on [SpecialAccounts]
    2. Click [New]
    3. Click [Key]
    4. Type [UserList]
  5. Add [DWORD (32bit) Value]s
    1. Click right button on right panel of [UserList]
    2. Click [New]
    3. Click [DWROD (32bit) Value]
    4. Type user account that you want to hide
    • Repeat this 4 steps as many as accounts that you want to hide
    • Make sure it is 0(zero). If this value is 1, you can see the user account on logon

2012-08-08

How to install GIT Server on Windows

As you know, GIT is one of source code management system. And it's ability includes a distributed revision control.
If you don't need any central integrated server, use only msysgit.
If you want to control GIT by GUI, use msysgit and TortoiseGIT that is front-end for msysgit.

The following instruction is how to install GIT repository server on Windows.

  • Summary
    • Setup
      • Install Cygwin
      • Setup SSH daemon
      • Add user for GIT service
      • (optional) Install Gitolite for managing accounts
    • Use GIT
      • Create Repository
      • Push project on developer's system
      • Download and install TortoiseGIT and MsysGit
  1. Install Cygwin
    • Download Cygwin installer on cygwin.com
    • Run setup.exe
    • Add [git] in [Devel] and [openssh] in [Net] and [python] in [Python]
  2. Setup SSH
    • Add Environment Variable
      • Select [Properties] on [Computer]
      • Click [Advanced system settings] on Control Panel > System and Security > System]
      • Click [Environment Variables...]
      • Click [New...] on System variables pannel
      • Type [CYGWIN] for [Variable name] and [ntsec] for [Variable value]
      • Click [OK]
    • Run [Cygwin Bash Shell] as Administrator
      • $ ssh-host-config  <= setup sshd
      • Answer [yes] for most questions
      • Answer [no] for question about using a different username for running the service
      • $ cygrunsrv -S sshd  <= run sshd
  3. Add user
    * There are no users in Cygwin that do not exist in Windows first. Create the Windows user first then use mkpasswd to add that user to /etc/passwd.
    • On Control panel
      • Control Panel > User Accounts and Family Safety > Add or remove user accounts
      • Create a new account
    • On command prompt
      • $ net user git password /add /yes
      • $ net localgroup <an_local_group> git /add
      • $ mkpassd -l -u git >> /etc/passwd  <= on Cygwin shell
      • Update git's home directory to /cygdrive/d/git-repository in the file /etc/passwd <= d is hard disk drive
  4. Add public key
    • $ ssh-keygen
    • $ cd .ssh
    • $ cp id_rsa.pub /tmp
    • runas /user:git c:/cygwin/cygwin.bat <= on windows command prompt
    • $ cp /tmp/id_rsa.pub ~/.ssh/authorized_keys
  5. Use Git
    • Create repository
      • login as git
      • $ mkdir PROJECT.git
      • $ cd PROJECT.git
      • $ git --bare init
    • Push project
      * in the project folder
      • git init
      • git add .
      • git commit -m 'initial commit'
      • git remote add origin git@[SERVER_NAME or IP]:PROJECT.git
      • git push origin master
    • Pull project
      • git clone git@[SERVER]:PROJECT.git

2012-07-29

How to install MS Office 2010 on Ubuntu 12.04

This instruction may not applicable for 64 bit version of MS Office 2010. I have failed to install 64 bit version.
  1. Install PlayOnLinux via command line tool for the latest version.
    * Ubuntu Software Center may install older version of PlayOnLinux.
    wget -q "http://deb.playonlinux.com/public.gpg" -O- | sudo apt-key add -
    sudo wget http://deb.playonlinux.com/playonlinux_precise.list -O /etc/apt/sources.list.d/playonlinux.list
    sudo apt-get update
    sudo apt-get install playonlinux
    
  2. Install 7zip that is required by PlayOnLinux
    sudo apt-get install p7zip-full
    
  3. Run PlayOnLinux
    * It may install Microsoft fonts if you run it first.
  4. Click Install and Select Office>Microsoft Office 2010
  5. Click Install

    * It may download and install the proper version of wine to run MS Office 2010 if you don't have it.
  6. Select the mount point of MS Office 2010 CD-ROM and Click Next

    * It may download and install DotNet Framework, Visual C++ 2005 Runtime and others to run the office.
  7. Look for the installation window when you see the following window.
  8. Proceed the installation process

    * It may install some components for running office.
  9. Complete to install

2012-07-28

org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER will not be exported or published.

WARNING in Eclipse : Classpath entry org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER will not be exported or published. Runtime ClassNotFoundExceptions may result.
  1. Open [Properties] of the project
  2. Select [Java Build Path]
  3. Select [Order and Export]
  4. Enable checkbox on [Maven Dependencies]
  5. Click [OK]
  6. Open [Windows>Show View>Other>Problems]
  7. Select the warning what you want to solve
  8. Press [Ctrl-1]
  9. Click [Finish] on Quick Fix window

2012-07-27

Chicago Zoological Society - Zoo Run Run for the Conservation Fund





How to resolve Loader Constraint Violation while running a Spring MVC Project on Tomcat 7

  • Loader Constraint Violation while running a Spring MVC Project on Tomcat 7

  • Error Message
    java.lang.LinkageError: loader constraint violation: when resolving interface method "javax.servlet.jsp.JspApplicationContext.getExpressionFactory()Ljavax/el/ExpressionFactory;" the class loader (instance of org/apache/jasper/servlet/JasperLoader) of the current class, org/apache/jsp/WEB_002dINF/views/home_jsp, and the class loader (instance of org/apache/catalina/loader/StandardClassLoader) for resolved class, javax/servlet/jsp/JspApplicationContext, have different Class objects for the type avax/el/ExpressionFactory; used in the signature

  • Cause
    Tomcat 7 uses el-api 2.2 and jsp-api 2.2.

  • Solution
    1. Open POM.XML file and Go to Dependencies page
    2. Select jsp-api : 2.1 > Click Properties > Change 2.1 to 2.2
    3. Save and run to check

2012-07-23

How to change the hostname in Linux

  1. See hostname
    hostname
    
    OR
    sysctl kernel.hostname
    
  2. Set the new hostname
    hostname NEW_HOSTNAME
    
    OR
    sysctl kernel.hostname=NEW_HOSTNAME
    
  3. Permanent change
    • on Ubuntu and any others based on Debian
      vi /etc/hostname
      
      replace OLD_HOSTNAME with NEW_HOSTNAME
      service hostname start
      
    • on CentOS and any others based on Redhat
      vi /etc/sysconfig/network
      
      replace HOSTNAME="OLD_HOSTNAME" with NEW_HOSTNAME
      /etc/rc.d/rc.sysinit
      

2012-07-15

How to deploy your project on Tomcat within Eclipse

Do you see the message [There are no resources that can be added or removed from the server.] when you select [Add and Remove...] on Tomcat server within Eclipse. If so, you need to add the Eclipse [Dynamic Web Module] facet.
  1. Go to [Properties] on your project.
  2. Check [Dynamic Web Module] at [Project Facets] page.
  3. Add your project on Tomcat and run.
  • Add [Maven Integration for Eclipse WTP] if you cannot find [Dynamic Web Module]

2012-07-14

How to install Eclipse Marketplace client

  1. Click [Help]->[Install New Software...]
  2. Select [Indigo Update Site] at [Work with:]
    If you cannot find it, click [Add...] and then input
    [Name] : Indigo Update Site
    [Location] : http://download.eclipse.org/releases/indigo
    
  3. Check [General Purpose Tools]->[Marketplace Client] and Install it.
  4. Restart Eclipse and See [Help]->[Eclipse Marketplace...]

2012-07-12

How to add SyntaxHighlighter to blog on Blogger.com

Visit SyntaxHighlighter homepage for more detailed information.
  1. Enter the setup page of your blog and then click [Template] > [Edit HTML]
  2. Copy the following code and paste it just above </head>
  3. <!--Core of SyntaxHighlighter-->
    <link href='http://alexgorbatchev.com/pub/sh/current/styles/shCore.css' rel='stylesheet' type='text/css'/>
    <link href='http://alexgorbatchev.com/pub/sh/current/styles/shThemeEclipse.css' rel='stylesheet' type='text/css'/>
    
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shCore.js' type='text/javascript'/>
    
    <!--Support languages-->
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushBash.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushCpp.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushCSharp.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushCss.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushDiff.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJava.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJScript.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushPerl.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushPhp.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushPlain.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushPython.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushRuby.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushSql.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushVb.js' type='text/javascript'/>
    <script src='http://alexgorbatchev.com/pub/sh/current/scripts/shBrushXml.js' type='text/javascript'/>
    
    <!--Activate SyntaxHighlighter-->
    <script language='javascript'>
     SyntaxHighlighter.config.bloggerMode = true;
     SyntaxHighlighter.config.clipboardSwf = 'http://alexgorbatchev.com/pub/sh/current/scripts/clipboard.swf';
     SyntaxHighlighter.all();
    </script>
    
  4. Write your code between <pre class="brush:[TYPE]"> and </pre> tags in HTML mode.
    [TYPE] can be one of language that can be found at shBrush[TYPE].js at the above code.
    <pre class='brush:html'>
    YOUR SOURCE CODE
    </pre>
    
  5. Expand the below for more themes
    Default <link href='http://alexgorbatchev.com/pub/sh/current/styles/shThemeDefault.css' rel='stylesheet' type='text/css'/>
    Django
    <link href='http://alexgorbatchev.com/pub/sh/current/styles/shThemeDjango.css' rel='stylesheet' type='text/css'/>
    
    Eclipse
    <link href='http://alexgorbatchev.com/pub/sh/current/styles/shThemeEclipse.css' rel='stylesheet' type='text/css'/>
    
    Emacs
    <link href='http://alexgorbatchev.com/pub/sh/current/styles/shThemeEmacs.css' rel='stylesheet' type='text/css'/>
    
    FadeToGrey
    <link href='http://alexgorbatchev.com/pub/sh/current/styles/shThemeFadeToGrey.css' rel='stylesheet' type='text/css'/>
    
    Midnight
    <link href='http://alexgorbatchev.com/pub/sh/current/styles/shThemeMidnight.css' rel='stylesheet' type='text/css'/>
    
    RDark
    <link href='http://alexgorbatchev.com/pub/sh/current/styles/shThemeRDark.css' rel='stylesheet' type='text/css'/>
    
  6. Visit here for more bundled brushes

2012-07-11

How to configure OCFS2

What is OCFS2? Visit this web site.
  1. Connect iSCSI
  2. iscsiadm -m discovery -p [IP_OF_NAS] -t st
    iscsiadm -m node -login
    

  3. Check if iSCSI is connected correctly
  4. fdisk -l
    
    Success if you can see [/dev/sdX]
    * X may be b, but it can be c, d or other if you have several attached HDDs.

  5. Generate Cluster
  6. /etc/ocfs2/cluster.conf
    
    • Configure Cluster Driver : /etc/init.d/o2cb configure
    • NM : Node Manager, cluster.conf - Track status of all installed nodes
    • HB : Heartbeat - Notify UP/DOWN status when a node join/drop into a cluster
    • TCP : Communicate inter-nodes
    • DLM : Distributed Lock Manager - Track status and owner of LOCK
    • CONFIGFS : Configuration File System mounted to User Space(/config)
    • DLMFS : User Space Interface for Kernel Space DLM

  7. Make partition
  8. fdisk /dev/sdX
    
    or
    cfdisk /dev/sdX
    

  9. Make filesystem(run once on a server)
  10. mkfs -t ocfs2 /dev/sdb1
    

  11. Mount filesystem(run on all servers)
  12. mount -t ocfs2 -o _netdev,nointr /dev/sdb1 /mnt/ocfs2
    

  13. Test read/write operation

How to install Tomcat and IIS

Summary
  1. Add isapi_redirect.dll on IIS
  2. Add [VirtualDirectory] and set [Enabled] on [HandlerMapping]
    Add [ISAPI Filters] on [Web Site] including the added VirtualDirectory
    Add [ISAPI and CGI Restrictions] on [Server]
    

  3. Configure Tomcat
  4. [isapi_redirect.properties] in [TOMCAT_HOME]/ISAPI
    [workers.properties] and [uriworkermap.properties] in [TOMCAT_HOME]/conf
    

How to install Tomcat and IIS
  1. Install JDK, Tomcat(ex, C:\ApacheTomcat), and place Tomcat connector into [TOMCAT_HOME]\ISAPI

  2. Configure IIS
    1. Add Tomcat into [SVR]-[ISAPI and CGI Restrictions]

    2. Add Tomcat into [SVR]-[Handler Mappings] and check Execute on [Edit Feature Permissions]



    3. [Add Virtual Directory], Its name will be used as [extension_uri] of Tomcat Connector


    4. Add ISAPI Filters


  3. Configure Tomcat
    1. Make sure the next 4 elements at [TOMCAT_HOME]/conf/Server.xml
      <Connector port="8080" protocol="HTTP/1.1“ connectionTimeout="20000” redirectPort="8443" />
      <Connector port="8009" protocol="AJP/1.3" redirectPort="8443" />
      <Host name="localhost"  appBase="webapps” unpackWARs="true" autoDeploy="true“>
      <Context path=" " docBase="C:/Homepage/Tomcat" reloadable="false" />

  4. Configure Tomcat Connector
    1. Make a file [isapi_redirect.properties] with following contents in the folder [TOMCAT_HOME]/ISAPI
      extension_uri=/jakarta/isapi_redirect.dll
      log_file=[TOMCAT_HOME]\logs\isapi_redirect.log
      log_level=info
      worker_file=[TOMCAT_HOME]\conf\workers.properties
      worker_mount_file=[TOMCAT_HOME]\conf\uriworkermap.properties

    2. Make a file [workers.properties] with following contents in the folder [TOMCAT_HOME]/conf
      worker.list=worker1, worker2
      worker.worker1.host=localhost
      worker.worker1.port=8009
      worker.worker1.type=ajp13
      #worker.worker2.host=otherhost
      #worker.worker2.port=8009
      #worker.worker2.type=ajp13
      

    3. Make a file [uriworkermap.properties] with following contents in the folder [TOMCAT_HOME]/conf
      /*.jsp=worker1
      /fedex/*=worker1

How to install Android SDK in SpringSource Tool Suite on Linux Mint and Ubuntu


1.       Install Android SDK
a.       Download Android SDK
b.      Extract the file into any folder. I usually install applications into /opt when I don’t use a package manager.
c.       Run [/opt/android-sdk-linux/tools/android]

e.      Select APIs and Click [Install Packages…]
2.       Setup Eclipse
a.       Run Eclipse. I use SpringSource Tool Suite.
b.      Click [Help > Install New Software…]
c.       Input (https://dl-ssl.google.com/android/eclipse/) in an edit box labeled [Work with:]
d.      Click [Add…]
e.      Input (ADT plugin) in an edit box labeled [Name] and Click [OK]
f.        Click [Select All] and [Developer Tools] and [NDK Plugins] may be selected.
g.       Click [Next >]

How to install SpringSource Tool Suite on Linux Mint and Ubuntu

  1. Download SpringSource Tool Suite
  2. Extract the file into any folder. I usually install applications into /opt when I don’t use a package manager.
  3. Create a menu item
    sudo vi /usr/share/applications/STS.desktop
    
  4. Content
    [Desktop Entry]
    Name=SpringSource Tool Suite
    Comment=SpringSource Tool Suite
    Exec=/opt/springsource/sts-2.9.2.RELEASE/STS
    Icon=/opt/springsource/sts-2.9.2.RELEASE/icon.xpm
    StartupNotify=true
    Terminal=false
    Type=Application
    Categories=Development;IDE;Java;
    
  5. You can see [SpringSource Tool Suite] in [Menu > Programming]

How to install Korean on Linux Mint and Ubuntu

  1. Install Korean Language
    Run [Menu > Control Center > Language Support]
    Click [Install / Remove Languages...]
    Check [Korean]
    Click [Apply Changes]
    
  2. Install Korean IME
    Run [Menu> Synaptic Package Manager]
    Type "ibus-hangul" in [Quick filter] edit box
    Select [Mark for Installation] on [ibus-hangul]
    Click [Apply]
    But not yet run IBus
    
  3. Set up Korean IME
    Run [Menu > Control Center > Language Support]
    Select [ibus] on [Keyboard input method system]
    Click [Close]
    
  4. Show IME
    Run [IBus] on [Menu]
    Now you can see IBus icon on notification area of taskbar.
    Click [IBus > Preferences]
    Select [Input Method] tab page
    Check [Customized active input methods]
    Select [Select an input method > Korean > Korean]
    Click [+Add]
    Now you can type Korean.
    
* If you cannot change to Korean with ALT_RIGHT on Ubuntu, remove [ALT] for [HUD].