Wednesday, December 12, 2012

optika

Pasivne optičke komponente

Završne optičke kutije, optičke distributivne kutije, optički patch-paneli i konektori se koriste za konektorsko terminiranje dovodnih optičkih kablova za spoljaljašnju instalaciju i njihovo pripremanje za priključenje na aktivnu opemu ili prespajanje na druge optičke linije.
Optički patch-panel
Optički patch-panel je pasivna komponenta fiber optičkog sistema gde se završavaju optički kablovi (spoljašnji ili unutrašnji) optičkim konektorima, a postavlja se u rack orman. Na prednjoj strani optičkog patch-panela montirani su optički adapteri (sadrži različit broj optičkih portova, koji mogu biti različitih tipova) za spajanje optičkih konektora. U adapter se sa zadnje strane postavlja konektor dovodnog optičkog kabla (koji je završen spajanjem na pig-tail ili direktnom montažom konektora), a sa prednje strane konektor patch-cord-a. Optički patch-panel predstavlja distributivni centar za međusobno prespajanje kablova ili njihovo spajanje sa komunikacionom opremom. Ovakve veze se obezbeđuju preko pach-cord-ova koji na svojim krajevima imaju konektore.
Optički patch panel je izrađen od čelika ili plastike i potpuno je zatvorene konstrukcije dela za smeštanje optičkih vlakana dolaznih kablova i unutrašnjih konektora. Ovim je fiber optički deo pasivnog dela mreže odvojen od ostalih pasivnih komponenata i time zaštićen od potencijalnog oštećenja. Sa prednje strane optičkog patch-panela nalaze se oznake portova, čime je olakšano kasnije održavanje optičkog dela mreže. Unutar panela nalaze se vođice za postavljanje optičkog vlakna kako bi se obezbedilo savijanje vlakana na dozvoljeni radijus.
pasiv1
Optički patch - panel
Optička distributivna kutija
Distributivna optička kutija je po nameni i konstrukciji veoma slična optičkom patch-panelu, ali se koristi zbog veličine prostora za završetak optičkog kabla ili nedostatka prostora za rack orman. Distributivna kutija se pričvršćuje na zid ili se postavlja u unutrašnjost manjih komunikacionih ormana, i namenjena je za završavanje optičkih kablova. Tehnologija završetka optičkog kabla je ista kao kod patch-panela. Na bočnoj strani optičke distributivne kutije su montirani optički adapteri za spajanje optičkih konektora. U adapter se sa zadnje strane postavlja konektor dovodnog optičkog kabla, a sa prednje strane konektor patch-cord-a. Optička distributivna kutija predstavlja distributivni centar za spajanje dovodnog optičkog kabla sa komunikacionom opremom ili dalje razvođenje optičke instalacije. Ovakve veze se obezbeđuju preko pach-cord-ova koji na svojim krajevima imaju konektore.
Optička distributivna kutija može biti izrađena od čelika ili plastike i potpuno je zatvorene konstrukcije dela za smeštanje optičkih vlakana dolaznih kablova i unutrašnjih konektora. Optički portovi mogu biti različiti, zavisno od tipa optičkog konektora koji treba da se priključi. Unutar optičke distributivne kutije nalaze se vođice za postavljanje optičkog vlakna kako bi se obezbedilo savijanje optičkog vlakna na dozvoljeni radijus.
pasiv2
Optička distributivna kutija

Optička spojnica za spoljašnju instalaciju
Optička spojnica je namenjena za spajanje deonica optičkih kablova i/ili za njihovo račvanje. Namenjena je upotrebi u spoljašnjoj sredini. Zadatak ove spojnice je da obezbedi hermetičku i mehanički stabilnu sredinu za ogoljena optička vlakna i njihove spojeve. Ovakva spojnica je otporna na uticaje spoljašnje sredine: UV zraci, voda, umereno agresivne hemikalije (hemikalije koje ne mogu rastvoriti PE, ali utiču na druge materijale) i slično.
Optička spojnica se sastoji iz više elemenata: metalnog kućišta, optičkih modula i plastičnog oklopa. Metalno kućište obezbeđuje pričvršćivanje spoljnih elemenata optičkog kabla i mehaničku stabilnost optičkih modula. Optički modul služi za fiksiranje spojeva optičkih vlakana i smeštanje viška dužine vlakana, uz obezbeđenje bezbednog prečnika savijanja optičkog vlakna. Plastični oklop uz primenu zaptivnih elemenata obezbeđuje kompaktnost odn. robusnost spoja optičkih kablova, i obezbeđuju hermetičnost zaptivanja celokupne spojnice.
Optička spojnica za spoljašnju instalaciju se postavlja u šahtovima ili u prostorijama gde se montiraju završne spojnice kablova na ulazima u zgrade. Optička spojnica se mora postaviti, tako da ne izaziva savijanje optičkih kablova na nedozvoljeni prečnik savijanja.
pasiv3
pasiv4
Optička spojnica za spoljašnju montažu
Optički konektori

Optički konektori su pasivne komponente prenosnih sistema sa optičkim vlaknima. Služe za fizičko priključenje optičkih vlakana na aktivne komponente optičkih prenosnih sistema ili da se preko njih izvrše prespajanja vlakana mehaničkim, lako razdvojivim putem.
Najvažniji deo konektora je ferula (centralna cevčica u konektoru) kroz koju je probušen kanal dimenzije spoljnog prečnika omotača (125 mikrona) uvećan za par mikrona. Ovim se obezbeđuje direktan prolaz optičkog vlakna kroz konektor. Materijali za izradu ferule optičkog konektora su: čelik, cirkonijum ili kompozitne plastične mase. Preciznost izrade otvora optičkog konektora uslovljava aksijalno poravnanje sučeljenih optičkih vlakana u adapteru, odnosno optičkog vlakna i aktivnog dela elektronike. Kućište konektora je element po kome se optički konektori najviše razlikuju. Uloga kućišta je da obezbedi čvrstu vezu konektora sa odgovarajućim adapterom ili kućištem aktivne komponente.
Postoji više tipova konektora, zavisno od standarda, proizvođača, tipa vlakna ili kućišta emisione i prijemne elektronike. Takođe optički konektori se ne dele prema nameni već prema tipu kućišta u koje se priključuju. Fiber optička tehnologija prenosa podataka ima nekoliko tipova „standardnih“ konektora: ST, SC, FC/PC, E2000, LC, MT-RJ itd.
pasiv5
Različiti tipovi optičkih konektora

Optički konektor tipa ST
ST konektori je načinjen po ugledu na BNC konektor koaksijalnih kablova.
Konstrukcija optičkog konektora obuhvata nekoliko delova:
• ferula od cirkonijuma,
• metalno ili plastično kućište za priključenje,
• prsten za pričvršćivanje rasteretnog elementa (kevlara) optičkog kabla, i
• aksijalni ojačavački element (rasteretni bužir koji onemogućava kritično savijanje vlakna na ulazu u konektor).
Osobine optičkog ST konektora su:
• uneto slabljenje konektora – max. 0,6 dB (srednje 0,25 dB)
• promena slabljenja posle ponovljenog priključenja (500 priključenja) – max. 0,3 dB
• promena slabljenja usled termičkog cikliranja (-40oC do + 80oC) – max. 0,5 dB
• promena slabljenja usled aksijalnog opterećenja na montirani kabel sa “tight” zaštitom vlakna (11 kg u trajanju od 1 min.) – max. 0,5 dB
pasiv6
Optički ST konektor

Optički konektor tipa SC
SC (Square-subscriber) konektori se koriste u mrežama gde su brzine prenosa podataka 100 Mb/s. Ovaj konektor je načinjen po ugledu na RJ konektor paričnih kablova, i prihvaćen je prema ANSI/TIA/EIA-568 za standard pri ožičavanju komercijalnih zgrada.

Konstrukcija optičkog konektora obuhvata nekoliko delova:
• ferula od cirkonijuma,
• plastično kućište za priključenje,
• prsten za pričvršćivanje rasteretnog elementa optičkog kabla, i
• aksijalni rasteretni bužir.
Osobine optičkog SC konektora su:
• uneto slabljenje konektora – max. 0,5 dB (srednje 0,25 dB)
• promena slabljenja posle ponovljenog priključenja (500 priključenja) – max. 0,3 dB
• promena slabljenja usled termičkog cikliranja (-40oC do + 80oC) – max. 0,5 dB
• promena slabljenja usled aksijalnog opterećenja na montirani kabel sa “tight” zaštitom vlakna (11 kg u trajanju od 1 min.) – max. 0,5 dB
pasiv7
Optički SC konektor
Optički konektor tipa FC/PC
Optički konektori tipa FC/PC najčešće koriste u telekomunikacionim mrežama, i montiraju se na monomodno optičko vlakno. Karakteristika ovog optičkog konektora je njegov konveksan izgled vrha konektora kako bi se obezbedio fizički kontakt (Physical Conntact) vlakana.

Konstrukcija optičkog konektora obuhvata nekoliko delova:
• ferula od cirkonijuma
• telo konektora,
• prsten za fiksno priključenja konektora,
• prsten za pričvršćivanje rasteretnog elementa optičkog kabla, i
• aksijalni rasteretni bužir.
Osobine optičkog FC/PC konektora su:
• uneto slabljenje konektora – max. 0,2 dB
• promena slabljenja posle ponovljenog priključenja (500 priključenja) – max. 0,2 dB
• promena slabljenja usled termičkog cikliranja (-40oC do + 80oC) – max. 0,2 dB
• povratno slabljenje - max. - 35 dB
pasiv8
Optički FC/PC konektor
Minijaturni SFF optički konektori
Nekoliko svetskih proizvođača je proizvelo «svoj» minijaturni optički konektor, te su se na tržištu pojavili konektori MT-RJ, Opti-Jack, LC (po ugledu na RJ-45). Ovakvi konektori spadaju u grupu SFF (Small Form Factor) konektora. Razlog je povećavan broj zahteva za izvođenje instalacija FTTD (vlakno do radnog stola), time i broj optičkih priključaka u mreži porastao i doveo do potrebe za većom gustinom pakovanja optičkih konekcija u komunikacionim ormanima.

pasiv91011
SFF konektor i adapter tipa LC
pasiv1213
SFF konektor tipa MT-RJ

Način postavljanja optičkog konektora
Osnovno u montiranju optičkog konektora bez obzira na tip je da je neophodno dovesti optičko vlakno do "čela" konektora i obezbediti visok stepen njihovog poravnanja. Takođe je potrebno obezbediti mehaničku povezanost optičkog kabla sa telom optičkog konektora. Ovaj postupak pričvršćivanja ojačavačkog elementa optičkog kabla-kevlara na konektor se najčešće izvodi krimpovanjem, odnosno stezanjem posebnim tipom klešta .
pasiv14
Delovi montiranog optički konektora

Kvalietet i tipovi konektora prema načinu poliranja
Optički konektori su u početnom stadijumu polirani sa ravnim čelom («flat polish»), te zbog se zbog smanjenja unetog slabljenja pristupilo konveksnom poliranju kako bi se obezbedio kontakt optičkih vlakana u konektorima.
Zahtevi korisnika za sve većim brzinama prenosa su uslovili da se montaža konektora vrši tako da bude povećano povratno slabljenje zbog zaštite emisionog dela linijske opreme. Prema nivou povratnog slabljenja razlikujemo nekoliko tipova optičkih konektora sa konveksnim «čelom» - PC (Physical Contact):
• PC – sferno polirani konektor povratnog slabljenja = - 35 dB
• SPC (Super PC) – sferno polirani konektor povratnog slabljenja = - 45 dB
• UPC (Ultra PC) – sferno polirani konektor povratnog slabljenja max. -55 dB
• APC (Angled PC) – sferno polirani konektor povratnog slabljenja max. -65 dB
pasiv15
Načini poliranja optičkih konektora

Ugaono poliran optički konektor (Angled Physical Contact)
Povratni svetlosni signal utiče na promenljivost snage izvora, kao i na talasnu distorziju (waveform distorsion) i fazni šum (phase noise). Pored pomenutog takođe izaziva fenomen poznat kao «menjanje modova» (mode hopping) što izaziva pomeranje centralne talasne dužine emitovane svetlosti lasera. Stoga je bilo neophodno obezbediti povratno slabljenje na nivou –60dB, što je tehnološki bilo neizvodljivo u tehnici UPC. Rešenje je nađeno u kosom poliranju optičkog konektora što je rezultiralo povratnim svetlosnim signalom koji je bio van numeričkog otvora vlakna u koje se vraća, time je smanjena količina povratne svetlosti.
pasiv16
Princip rada ugaono poliranog optičkog konektora
Adapteri za optičke konektore
Adapteri se koriste za povezivanje dva optička konektora "čelo-u-čelo". Adapteri mogu biti istovrsni ili hibridni. Istovrsni adapteri služe za povezivanje dva konektora istog tipa, dok hibridni adapteri povezuju dva konektora različitih tipova. Postoje "muški", "ženski" i "muško - ženski" adapteri, zavisno od tipa priključenja koje se izvodi.
Adapteri se najčešće postavljaju na optičke distributivne kutije i optičke panele, a kako bi se obezbedilo priključenje optičkih kablova na aktivne komponente.
pasiv17
ST - ST adapter "ženski"
pasiv18
SC - SC adapter "ženski"
pasiv19
FC/PC - ST adapter "muški"
Dodaci optičkih konektora
U dodatke koji se koriste uz optičke konektore mogu se ubrojati optički kablovi sa montiranim konektorima i konektorski adapteri.

Kombinacija optičkih kablova i konektora
Optički konektori mogu se montirati na optičko vlakno samo sa jedne strane i koristiti za završavanje optičkih vlakana iz kablova za spoljašnju instalaciju. Ovakva kombinacija vlakna i jednog konektora naziva se pig-tail. Za priključenje optičkih kablova koji su završeni na panelima i njihovo priključenje na linijsku opremu, koriste se kablovi koji imaju sa obe strane konektor, a kabel se sastoji od optičkog vlakna sa prijanjajućom strukturom, kevlarom i PVC plaštom.
pasiv20
Kombinacija optički konektor i optički kabel
pasiv21
Načini završavanja optičkog kabla (pig-tail-om i konektorom)

Wednesday, October 10, 2012

Configuring Static Route Tracking using IP SLA (Basic)

Configuring Static Route Tracking using IP SLA (Basic)PDFPrintEmail

(29 votes, average 4.72 out of 5)
Written by Administrator
AddThis Social Bookmark Button
In today's network environment, redundancy is one of the most important aspects, whether its on the LAN side or on the WAN side. In this topic I will be covering WAN redundancy with multiple WAN links terminating on a single router.
The best and simplest way to achieve WAN redundancy on Cisco devices is to use Reliable Static backup routes with IP SLA tracking.
IP SLAs is a feature included in the Cisco IOS Software that can allow administrators the ability to Analyze IP Service Levels for IP applications and services. IP SLA's uses active traffic-monitoring technology to monitor continuous traffic on the network. This is a reliable method in measuring over head network performance. Cisco Routers provide IP SLA Responders that give accuracy of measured data across a network.
With IP SLAs, routers and switches perform periodic measurements. The number and type of available measurements are vast and in this article I will be covering just the ICMP ECHO feature. IP SLA in itself is a very big topic to cover J
Let us take an example of a basic redundant WAN link scenario as shown below:
tk-cisco-ipsla-1
In the above figure the Cisco device is connected to two WAN links ISP1 and ISP2. The most common setup that we use in day to day life is to have to default routes configured on the Cisco router pointing to the respective next hop IPs as shown below:
R1(config)# ip route 0.0.0.0 0.0.0.0 2.2.2.2
R1(config)# ip route 0.0.0.0 0.0.0.0 3.3.3.3 10
If you notice the Administrative Distance for the secondary route pointing to ISP2 is increased to 10 so that it becomes the backup link.
The above configuration with just two floating static routes partially accomplishes our requirement as it will work only in the scenario where the routers interfaces connected to the WAN link are in up/down or down/down status. But in a lot of situations we see that even though the links remain up but we are not able to reach the gateway, this usually happens when the issue is at the ISP side.
In such scenarios, IP SLAs becomes an engineer's best friend. With around six additional IOS commands we can have a more reliable automatic failover environment.
Using IP SLA the Cisco IOS gets the ability to use Internet Control Message Protocol (ICMP) pings to identify when a WAN link goes down at the remote end and hence allows the initiation of a backup connection from an alternative port. The Reliable Static Routing Backup using Object Tracking feature can ensure reliable backup in the case of several catastrophic events, such as Internet circuit failure or peer device failure.
IP SLA is configured to ping a target, such as a publicly routable IP address or a target inside the corporate network or your next-hop IP on the ISP's router. The pings are routed from the primary interface only. Following a sample configuration of IP SLA to generate icmp ping targeted at the ISP1s next-hop IP.
R1(config)# ip sla 1
R1(config)# icmp-echo 2.2.2.2 source-interface FastEthernet0/0
R1(config)# timeout 1000
R1(config)# threshold 2
R1(config)# frequency 3
R1(config)# ip sla schedule 1 life forever start-time now
Please note that the Cisco IP SLA commands have changed from IOS to IOS to know the exact command for IOS check the Cisco documentation. The above commands are for IOS 12.4(4)T, 15.(0)1M, and later releases.
The above configuration defines and starts an IP SLA probe.
The ICMP Echo probe sends an ICMP Echo packet to next-hop IP 2.2.2.2 every 3 seconds, as defined by the “frequency” parameter.
Timeout sets the amount of time (in milliseconds) for which the Cisco IOS IP SLAs operation waits for a response from its request packet.
Threshold sets the rising threshold that generates a reaction event and stores history information for the Cisco IOS IP SLAs operation.
After defining the IP SLA operation our next step is to define an object that tracks the SLA probe. This can be accomplished by using the IOS Track Object as shown below:
R1(config)# track 1 ip sla 1 reachability
The above command will track the state of the IP SLA operation. If there are no ping responses from the next-hop IP the track will go down and it will come up when the ip sla operation starts receiving ping response.
To verify the track status use the use the “show track” command as shown below:
R1# show track

Track 1
IP SLA 1 reachability
Reachability is Down
1 change, last change 00:03:19
Latest operation return code: Unknown
The above output shows that the track status is down. Every IP SLAs operation maintains an operation return-code value. This return code is interpreted by the tracking process. The return code may return OK, OverThreshold, and several other return codes.
Different operations may have different return-code values, so only values common to all operation types are used. The below table shows the track states as per the IP SLA return code.
Tracking
Return Code
Track State
Reachability
OK or over threshold
(all other return codes)
Up
Down
The Last step in the IP SLA Reliable Static Route configuration is to add the “track” statement to the default routes pointing to the ISP routers as shown below:
R1(config)# ip route 0.0.0.0 0.0.0.0 2.2.2.2 track 1
R1(config)# ip route 0.0.0.0 0.0.0.0 3.3.3.3 10
The track number keyword and argument combination specifies that the static route will be installed only if the state of the configured track object is up. Hence if the track status is down the secondary route will be used to forward all the traffic.
If you would like to learn how to configure IP SLA Tracking with Policy-Based Routing to automatically redirect specific type of traffic to other gateways or hosts, visit our Configuring Policy-Based Routing (PBR) with IP SLA Tracking - Auto Redirecting Traffic article.

Monday, May 28, 2012

creat new cert in zimbra 6

As root:
mkdir -p /root/backup/ssl/zimbra
mv /opt/zimbra/ssl/zimbra /root/backup/ssl/zimbra
cd /opt/zimbra/bin/
zmcertmgr createca -new
zmcertmgr createcrt -new -days 365
zmcertmgr deploycrt self
zmcertmgr deployca
zmcertmgr viewdeployedcrt

I really hope this works for you.

*********************************

ZCS Certificate CLI

The ZCS Certificate CLI commands for 7.0.x, 6.0.x and 5.0.x differ from 4.5.x. The following sections discuss the CLI tools for each version.

ZCS 7.0.x, 6.0.x, and 5.0.x

zmcertmgr

This command allows you to manage certificates.

General Guidelines

Follow these guidelines when using this command.
  • This tool must be run as root
Commercial Certificate Guidelines
Follow these guidelines when using this command to generate a commercial certificate.
  • The private key must exist in the /opt/zimbra/ssl/zimbra/commercial directory, and must be named commercial.key with its permission set to 740
  • The server certificate and the chain certificate files must exist in a temp directory. (E.g. /root/certs/)
  • The chain certificate files must be concatenated into one file called commercial_ca.crt

Syntax

zmcertmgr [options]

Description


Name Description
General Options
-help Displays usage options for zmcertmgr
Self-Signed Certificate Options
createca [-new] Generates a Certificate Authority (CA). The -new option forces the generation of a new CA.
deployca Deploys a CA.
createcsr <self|comm> [-new] [-subject subject] [-subjectAltNames "host1,host2"] Creates a certificate signing request (CSR) for either a self or commercially signed certificate authority. The -new option forces the generation of a new CSR. The -subject option allows you to specify the path in which the certificate is valid. The -subjectAltNames option allows you to specify additional hosts that may use the certificate other than the one listed in the subject. The default subject is "/C=US/ST=N\/A/L=N\/A/O=Zimbra Collaboration Suite/OU=Zimbra Collaboration Suite/CN=${zimbra_server_hostname}".
createcrt [-new] [-days validation days] [-subject subject] [-subjectAltNames "host1,host2"] Creates a self-signed certificate based on the CSR generated using createcsr. The -new option forces the generation of a new certificate. The -days option assigns a number of days for which the certificate is valid. The -subject option allows you to specify the path in which the certificate is valid. The -subjectAltNames allows you to specify additional hosts that may use the certificate other than the one listed in the subject. The default subject is "/C=US/ST=N\/A/L=N\/A/O=Zimbra Collaboration Suite/OU=Zimbra Collaboration Suite/CN=${zimbra_server_hostname}".
deploycrt <self> Deploys a self-signed certificate.
Self-Signed and Commercial Certificate Options
deploycrt <comm> [certfile] [ca_chain_file] Deploys a commercial certificate. Specify the certificate file and the certificate authority (CA) chain file.
savecrt Saves a certificate
viewcsr <self|comm> [csr_file] Shows a certificate signing request (CSR). Specify self if the CSR is self-signed. Specify comm if the certificate is commercial. Specify the CSR file to view.
viewdeployedcrt [all|ldap|mta|proxy|mailboxd] Shows a deployed certificate. This option only works for the local server.
viewstagedcrt <self|comm> [certfile] Shows a staged certificate. A staged certificate is placed in a staging file, where all files that will be deployed with the certificate are kept. You can use the staging area to verify that you are ready to deploy a certificate. Specify self if the certificate is self-signed. Specify comm if the certificate is commercial. Specify the certificate file to view.
verifycrt <self|comm> [priv_key] [certfile] Verifies a certificate. Specify self if the certificate is self-signed. Specify comm if the certificate is commercial. Specify the certificate key. Specify the certificate file.
verifycrtchain <ca_file> <certfile> Verifies a certificate chain. Specify self if the certificate is self-signed. Specify comm if the certificate is commercial. Specify the certificate key. Specify the certificate file.

Examples

The following are examples of using the above options for different installation scenarios.
Single-Node Self-Signed Certificate
1. Begin by generating a new Certificate Authority (CA).
 /opt/zimbra/bin/zmcertmgr createca -new
2. Then generate a certificate signed by the CA that expires in 365 days.
 /opt/zimbra/bin/zmcertmgr createcrt -new -days 365
3. Next deploy the certificate.
 /opt/zimbra/bin/zmcertmgr deploycrt self
4. Next deploy the CA.
 /opt/zimbra/bin/zmcertmgr deployca
5. To finish, verify the certificate was deployed to all the services.
 /opt/zimbra/bin/zmcertmgr viewdeployedcrt
Multi-Node Self-Signed Certificate
1. Begin by generating a new Certificate Authority (CA).
 /opt/zimbra/bin/zmcertmgr createca -new
2. Then generate a certificate signed by the CA that expires in 365 days with either wild-card or subject altnames.
 /opt/zimbra/bin/zmcertmgr createcrt -new -days 365 -subject "/C=US/ST=CA/L=NVA/O=ZCS/OU=ZCS/CN=*.domain.tld"
 /opt/zimbra/bin/zmcertmgr createcrt -new -days 365 -subjectAltNames "host1.domain.tld,host2.domain.tld"
3. Next, deploy the certificate to all nodes in the deployment.
 /opt/zimbra/bin/zmcertmgr deploycrt self -allserver
4. To finish, verify the certificate was deployed.
 /opt/zimbra/bin/zmcertmgr viewdeployedcrt
Note: The option viewdeployedcrt only works for the local server.
Single-Node Commercial Certificate
1. Begin by generating a Certificate Signing Request (CSR).
 /opt/zimbra/bin/zmcertmgr createcsr comm -new -subject "/C=US/ST=CA/L=Sunnyvale/O=Yahoo/OU=Zimbra Collaboration Suite" -subjectAltNames host.example.com
2. Next, submit the CSR to the SSL provider and get a commercial certificate in PEM format. Save the new certificate to a temporary file (e.g. /tmp/commercial.crt).
3. Now, download and save the root Certificate Authority (CA) from your provider to a temporary file. (e.g. /tmp/ca.crt)
4. Download any intermediary CAs from your provider to a temporary file. (e.g. /tmp/ca_intermediary.crt)
5. Combine root and intermediary CAs into a temporary file.
 cat /tmp/ca.crt /tmp/ca_intermediary.crt > /tmp/ca_chain.crt
6. Verify your commercial certificate.
 /opt/zimbra/bin/zmcertmgr verifycrt comm /opt/zimbra/ssl/zimbra/commercial/commercial.key /tmp/commercial.crt /tmp/ca_chain.crt
 **Verifying /tmp/commercial.crt against
 /opt/zimbra/ssl/zimbra/commercial/commercial.key
 Certificate (/tmp/commercial.crt) and private key
 (/opt/zimbra/ssl/zimbra/commercial/commercial.key) match.
 Valid Certificate: /tmp/commercial.crt: OK
7. Deploy your commercial certificate.
 /opt/zimbra/bin/zmcertmgr deploycrt comm /tmp/commercial.crt /tmp/ca_chain.crt
 ** Verifying /tmp/commercial.crt against
 /opt/zimbra/ssl/zimbra/commercial/commercial.key
 Certificate (/tmp/commercial.crt) and private key
 (/opt/zimbra/ssl/zimbra/commercial/commercial.key) match.
 Valid Certificate: /tmpt/commercial.crt: OK
 **Copying commercial.crt to /opt/zimbra/ssl/zimbra/commercial/commercial.crt
 **Appending ca chain /tmp/ca_chain.crt to
 /opt/zimbra/ssl/zimbra/commercial/commercial.crt
 **Saving server config key zimbraSSLCeretificate…done.
 **Saving server config key zimbraSSLPrivateKey…done.
 **Installing mta certificate and key…done.
 **Installing slapd certificate and key…done.
 **Installing proxy certificate and key…done.
 **Creating pkcs12 file /opt/zimbra/ssl/zimbra/jetty.pkcs12…done.
 **Creating keystore file /opt/zimbra/mailbox/etc/keystore…done.
 **Installing CA to /opt/zimbra/conf/ca…done.
8. To finish, verify the certificate was deployed.
 /opt/zimbra/bin/zmcertmgr viewdeployedcrt

Wednesday, May 23, 2012

Cisco PPTP VPN server

On the Cisco IOS router

First you must make some changes on your router. First, you must enable VPDN (virtual private dial-up networking). This is used for VPN client connectivity, as opposed to site-to-site, always up, VPN connectivity. To do so use this command:
Router(config)# vpdn enable
Create a VPDN group configured to PPTP, just like the Microsoft VPN client will use, by default:
Router(config)# vpdn-group TEST-VPN
Router(config-vpdn)# accept-dialin
Router(config-vpdn)# protocol pptp
Router(config-vpdn)# virtual-template 1
Router(config-vpdn)# exit
Here, we will configure our interfaces to match the diagram. Naturally, your IP address configuration will vary:
Router(config)# interface ethernet0/0
Router(config-if)# ip address 10.253.15.19 255.255.0.0
Router(config-if)# no shutdown
Router(config)# interface ethernet0/1
Router(config-if)# ip address 10.123.123.123 255.255.255.0
Router(config-if)# no shutdown
Next, create your virtual-template that will apply to the inbound VPN connections. This template references the e0/1 interface for its IP address. It also references a pool of IP addresses that will be handed out to VPN clients. Finally, it configures the PPP encryption and authentication mechanisms to match what the Microsoft VPN client defaults to:
Router(config)# interface Virtual-Template1
Router(config-if)# ip unnumbered Ethernet0/1
Router(config-if)# peer default ip address pool defaultpool
Router(config-if)# ppp encrypt mppe auto required
Router(config-if)# ppp authentication ms-chap ms-chap-v2
Now, create the pool of IP addresses. This pool should not already be in use on the internal network you are connecting to:
Router(config)# ip local pool defaultpool 10.123.123.1 10.123.123.10
After that, create a test user:
Router(config)# username test password 0 test
Finally, configure authentication for PPP to use the local database. If you had a RADIUS server, this where you would point to the RADIUS server instead of the local database:
Router(config)# aaa new-model
Router(config)# aaa authentication ppp default local
The complete configuration looks like this:
username test password 0 test
aaa new-model
!
!
aaa authentication ppp default local
!
vpdn enable
!
vpdn-group TEST-VPN
! Default PPTP VPDN group
accept-dialin

protocol pptp

virtual-template 1

!
interface Ethernet0/0
ip address 10.253.15.19 255.255.0.0
no shutdown
interface Ethernet0/1
ip address 10.123.123.123 255.255.255.0

no shutdown

!
interface Virtual-Template1
ip unnumbered Ethernet0/1

peer default ip address pool defaultpool

ppp encrypt mppe auto required

ppp authentication ms-chap ms-chap-v2

!
ip local pool defaultpool 10.123.123.1 10.123.123.10

*********************************


vpdn enable
!
vpdn-group PPTP-Group
! Default PPTP VPDN group
 accept-dialin
  protocol pptp
  virtual-template 1
!
!
!
!
async-bootp gateway 10.123.3.1
async-bootp dns-server 206.13.28.12
   
interface Virtual-Template1
 ip address 10.123.3.1 255.255.255.0
 ip nat inside
 ip virtual-reassembly
 peer default ip address pool PPTP
 ppp encrypt mppe 128 required
 ppp authentication ms-chap-v2
   
ip local pool PPTP 10.123.3.100 10.123.3.200
  

Tuesday, February 21, 2012

How to restore Layer 2 full managed switch to factory default

How to restore Layer 2 full managed switch to factory default
Suitable for: TL-SG5426, TL-SL5428
There are two ways to restore Layer 2 full managed switch to factory default, one is to use the web interface, but sometimes you may not be able to log on the web interface. In this case, you should use console to restore it to factory default.
Use serial cable to connect your switch to a computer. Then power off the switch.
On your computer click start -> All Programs -> Accessories -> Communications -> Hyper Terminal to run Hyper Terminal. And there will pop up a dialog box as Picture 1 shows. Enter a name, here we use test for example. Then click OK.
Picture 1
Then you will see Picture 2, just click OK.
Picture 2
Change Port Settings as Picture 3 shows. Bits per second set to 9600, Data bits set to 8, Parity set to None, Stop bits set to 1 and Flow control set to None. Then click OK.
Picture 3
Then power on the switch, when you see Image Loader x.x.x.x, press Ctrl+U, it requires a password to enter the diagnose mode.
Picture 4
The password for TL-SL5428 is mercury while for TL-SG5426 it is sosupdate. Here we use TL-SL5428 for example. After enter mercury, you will see Picture 5.
Picture 5
Enter D and it will require you to enter the file name you want to delete. Please type startup1.cfg (startup1.cfg is the configuration file I have saved before).
Picture 6
Press Enter and type Y.

Picture 7
After that type Q and the switch will reboot automatically and then restore to factory default.
Caution: Please DO NOT do any other operations, or it may damage your switch.

Friday, February 10, 2012

Getif SNMP MIB Browser

http://www.wtcs.org/informant/getif.htm

I had a problem installing this in Windows 7, but was able to eventually get it to run.
The problem is with the Msflxgrd.ocx file which doesn't get registered in Windows 7.
This site provided some clues: http://www.ascentive.com/support/new/support_dll.phtml?dllname=Msflxgrd.ocx
And so did this site: http://social.answers.microsoft.com/Forums/en-US/w7repair/thread/471a9b26-88c1-4765-9417-bae27ff8fe3b
The manual process goes something like this:
Copy the Msflxgrd.ocx file to the windows\system32. That file can be found in the 'ascentive.com' link above. I also found this file in the sysWOW64 directory, but Windows 7 was giving me an error message saying it was not available.
Next, I did a right click on Start >> Accessories >> Command Prompt and selected 'Run as Administrator'.
Then I executed the following from the command line:
%systemroot%\SysWoW64\resvr32 \windows\sysWOW64\Msflxgrd.ocx
I had to run Getif as admin, but I expect changing permissions should be trivial.