Difference between revisions of "Ajcody-General-Notes"

m
m (Undo revision 62203 by Ajcody (talk))
 
(14 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{NotOfficial}}
+
{{BC|Zeta Alliance}}                         <!-- Note, this will also add [[Category: Zeta Alliance]] to bottom of wiki page. -->
 
+
__FORCETOC__                              <!-- Will force a TOC regards of size of article. __NOTOC__  if no TOC is wanted. -->
=General Notes=
+
<div class="col-md-12 ibox-content">
 +
=General Notes=             <!-- Normally will reflect page title. Is listed at very top of page. -->
 +
{{KB|{{ZETA}}|{{ZCS 8.5}}|{{ZCS 8.0}}|{{ZCS 7.0}}|}}            <!-- Can only handle 3 ZCS versions. -->
 +
{{WIP}}                                                <!-- For pages that are "work in progress". -->
  
 
==Actual General Notes Homepage==
 
==Actual General Notes Homepage==
Line 18: Line 21:
 
  cd /opt/zimbra/openldap/etc/openldap/schema/
 
  cd /opt/zimbra/openldap/etc/openldap/schema/
 
  more zimbra.schema
 
  more zimbra.schema
 +
 +
Made the following concerning zmlocalconfig's behavior:
 +
 +
* "RFE: zmlocalconfig sanity check and clean up of -i output"
 +
** http://bugzilla.zimbra.com/show_bug.cgi?id=52793
 +
 +
Also, with newer versions of ZCS, you can get it via zmprov - for example:
 +
 +
<pre>
 +
#zmprov desc -a zimbraFreeBusyExchangeAuthScheme
 +
    zimbraFreebusyExchangeAuthScheme
 +
        auth scheme to use
 +
 +
                  type : enum
 +
                  value : basic,form
 +
              callback :
 +
              immutable : false
 +
            cardinality : single
 +
            requiredIn :
 +
            optionalIn : cos,domain,globalConfig,account
 +
                  flags : accountInherited,domainInherited
 +
              defaults :
 +
                    min :
 +
                    max :
 +
                    id : 611
 +
        requiresRestart :
 +
                  since : 5.0.3
 +
        deprecatedSince :
 +
</pre>
 +
 +
Addition note, example,  for those checking source : src/6.0.7/com/zimbra/cs/account/ProvUtil.java.html
  
 
==Zimbra Contact Fields For CSV Import Mapping==
 
==Zimbra Contact Fields For CSV Import Mapping==
Line 56: Line 90:
  
 
I'm hoping the forum user simply renamed the top header column to match description fields that Zimbra knows and that it's in order of the data (left to right) that Horde normally exports in. You'll need to review it and make sure it fits with your exported data columns from Horde.
 
I'm hoping the forum user simply renamed the top header column to match description fields that Zimbra knows and that it's in order of the data (left to right) that Horde normally exports in. You'll need to review it and make sure it fits with your exported data columns from Horde.
 +
 +
===Admin With Curl And Wget===
 +
 +
You will most likely need to include :7071 in the url string to get around the pop-up issue that you would get if you used the same string in a web browser, without :7071 you'll see a permission error when trying to see/get data from a users account via the admin account.
 +
 +
curl -u admin:pass https://hostname:7071/home/user/Contacts
 +
wget https://admin:pass@hostname:7071/home/user/Contacts
  
 
==What's My Server Like==
 
==What's My Server Like==
To dump out your server details, these commands are useful.
+
To dump out your server details, these commands are useful. Login to your zimbra server and as the zimbra user do:
  
  zmprov gs yourdomainname
+
  zmprov gs `zmhostname`
 
  zmprov gacf
 
  zmprov gacf
 
  zmlocalconfig
 
  zmlocalconfig
Line 75: Line 116:
 
  zmmailboxdctl restart
 
  zmmailboxdctl restart
  
==Get Version From Ajax Client==
+
==How Do I Find Out What Version Of Zimbra I'm Using==
  
Put the below in the search field of the Ajax client:
+
See:
 +
* http://www.zimbra.com/forums/announcements/12153-don-t-forget-update-your-profile-version-info.html#post62754
 +
 
 +
===Get Version From Ajax Client===
 +
 
 +
In newer versions of ZWC, the Help > About will also state the ZCS server version being used.
 +
 
 +
For older version, put the below in the search field of the Ajax client and hit enter:
  
 
  $set:get version
 
  $set:get version
 +
 +
Also:
 +
 +
https://SERVERNAME/js/zimbraMail/share/model/ZmSettings.js
 +
 +
Search for the CLIENT_VERSION line.
 +
 +
====Other Ways To Get Version Of Server====
 +
 +
See this forum post:
 +
 +
* http://www.zimbra.com/forums/announcements/12153-don-t-forget-update-your-profile-version-info.html
  
 
==What's Compiled With Postfix==
 
==What's Compiled With Postfix==
  
Do the following (return is from my test box):
+
Moved to [[What%27s_Complies_With_Zimbra%27s_Postfix]]
 
 
postconf -m
 
btree
 
cidr
 
environ
 
hash
 
ldap
 
mysql
 
pcre
 
proxy
 
regexp
 
static
 
unix
 
  
 
==REST Information==
 
==REST Information==
Line 128: Line 175:
 
http://svn.sourceforge.net/viewvc/zimbra/trunk/ZimbraServer/docs/
 
http://svn.sourceforge.net/viewvc/zimbra/trunk/ZimbraServer/docs/
  
==Trouble Shooting Memory Issues==
+
----
 
 
===Basic Commands To Gather Data===
 
 
 
====PS====
 
Try adjusting the ps output:
 
* <pre>ps -eo pid,ppid,rss,vsize,pcpu,pmem,cmd -ww --sort=pid</pre>
 
** RSS (Resident Set Size) - The portion of a process that exists in physical memory (RAM). The rest of the program exists in swap. If the computer has not used swap, this number will be equal to VSIZE. RSS per unit time will show how much RAM the process is using over time.
 
** VSIZE (Virtual memory SIZE) - The amount of memory the process is currently using. This includes the amount in RAM and the amount in swap. VSIZE per unit time will show how large the process is over time.
 
 
 
====Free====
 
Using Free:
 
* <pre>free -o</pre>
 
** [ -o ] Disables the display of a "buffer adjusted" line. If the -o option is not specified, free subtracts buffer memory from the used memory and adds it to the free memory reported.
 
** "Memory Used" per unit time will show the "Memory Used" asymptotically approach the total amount of memory in the system under heavy use. This is normal, as RAM unused is RAM wasted.
 
** "Memory Used - Memory Buffered - Memory Cached" per unit time will give a good sense of the memory use of your applications minus the effects of your operating system. As you start new applications, this value should go up. As you quit applications, this value should go down. If an application has a severe memory leak, this line will have a positive slope.
 
** "Swap Used" per unit time will display the swap usage. When the system is low on RAM, a program called kswapd will swap parts of process if they haven't been used for some time. If the amount of swap continues to climb at a steady rate, you may have a memory leak or you might need more RAM.
 
 
 
You could also use watch with free to poll it:
 
* <pre>watch free</pre>
 
** or
 
* <pre>watch -n 1 -d free</pre>
 
 
 
====Top====
 
Top is nice, put you want to save output. Do the [-b batch] and [-n number of iterations] variables:
 
 
 
top -b -n1 > /tmp/top-output.txt
 
 
 
====Vmstat====
 
 
 
Gives a good overview as well:
 
 
 
vmstat
 
 
 
* The process-related fields are:
 
** r — The number of runnable processes waiting for access to the CPU
 
** b — The number of processes in an uninterruptible sleep state
 
** w — The number of processes swapped out, but runnable
 
*The memory-related fields are:
 
** swpd — The amount of virtual memory used
 
** free — The amount of free memory
 
** buff — The amount of memory used for buffers
 
** cache — The amount of memory used as page cache
 
*The swap-related fields are:
 
** si — The amount of memory swapped in from disk
 
** so — The amount of memory swapped out to disk
 
*The I/O-related fields are:
 
** bi — Blocks sent to a block device
 
** bo— Blocks received from a block device
 
*The system-related fields are:
 
** in — The number of interrupts per second
 
** cs — The number of context switches per second
 
* The CPU-related fields are:
 
** us — The percentage of the time the CPU ran user-level code
 
** sy — The percentage of the time the CPU ran system-level code
 
** id — The percentage of the time the CPU was idle
 
 
 
Polling data with vmstat:
 
* <pre>vmstat 1 10</pre>
 
** Displays one new line per second, but only for the next ten seconds
 
 
 
====Meminfo====
 
 
 
See below for description of the output for meminfo:
 
 
 
[http://www.redhat.com/advice/tips/meminfo.html Featured Article: /proc/meminfo Explained]
 
 
 
Do the following:
 
 
 
cat /proc/meminfo
 
  
 
[[Category:Community Sandbox]]
 
[[Category:Community Sandbox]]
 +
[[Category: Author:Ajcody]]
 +
[[Category: Zeta Alliance]]

Latest revision as of 16:38, 20 June 2016

General Notes

   KB 2490        Last updated on 2016-06-20  




0.00
(0 votes)
24px ‎  - This is Zeta Alliance Certified Documentation. The content has been tested by the Community.


Actual General Notes Homepage

Please see Ajcody-General-Notes

Zimbra Variables

Ways to check on different zimbra variables.

su - zimbra
zmlocalconfig -i
zmlocalconfig -d
cd /opt/zimbra/conf/attrs
more zimbra-attrs.xml
cd /opt/zimbra/openldap/etc/openldap/schema/
more zimbra.schema

Made the following concerning zmlocalconfig's behavior:

Also, with newer versions of ZCS, you can get it via zmprov - for example:

#zmprov desc -a zimbraFreeBusyExchangeAuthScheme
    zimbraFreebusyExchangeAuthScheme
        auth scheme to use

                   type : enum
                  value : basic,form
               callback :
              immutable : false
            cardinality : single
             requiredIn :
             optionalIn : cos,domain,globalConfig,account
                  flags : accountInherited,domainInherited
               defaults :
                    min :
                    max :
                     id : 611
        requiresRestart :
                  since : 5.0.3
        deprecatedSince : 

Addition note, example, for those checking source : src/6.0.7/com/zimbra/cs/account/ProvUtil.java.html

Zimbra Contact Fields For CSV Import Mapping

Please see /opt/zimbra/conf/zimbra-contact-fields.xml

This will show you what "fields" Zimbra is looking for and mapping to in regards to importing from another applications contact csv files.

One easy way to do this is the following:

  • From zimbra ajax client as a test user (or any old user) do an export Addressbook.
    • This is under the preference tab > Address Book > Import / Export > Export - select Addressbook and click Export button
  • Then open file file something like Excel or a Text Editor
    • Your only interested in the Top line - that gives the default fields for a Zimbra Addressbook.
    • You'll get something like this:
"company","companyPhone","email2","fileAs","firstName","homepageURL","imAddress3","lastName","otherIMLabel","workCity","workCountry","workEmail2","workEmail3","workEmail4","workEmail5","workPostalCode","workState","workStreet"
    • Note, ordering [left to right] isn't important. What is important, is the data lines up under the right column header.
  • With your other Mail system, export the addressbook to a csv file.
    • Open this file in another Excel window.
  • Copy the column data from the one Excel sheet and paste it into the appropriate column within the Zimbra Excel sheet.
  • Move as much as you can and then save.
    • For example:
"company","companyPhone","email2","fileAs","firstName","homepageURL","imAddress3","lastName","otherIMLabel","workCity","workCountry","workEmail2","workEmail3","workEmail4","workEmail5","workPostalCode","workState","workStreet"
"Apple Computer Inc.","1-800-MY-APPLE","","3","","http://www.apple.com","","","","Cupertino","United States","","","","","95014","CA","1 Infinite Loop"
  • Now you can try importing this csv file back into Zimbra.
  • Either with the webclient or you can use some on the CLI commands
    • See User_Migration for variations of CLI commands that could be used.
    • Here's the documented example:
    • curl -u schemers:password --data-binary @/tmp/new.csv http://server/service/home/schemers/contacts?fmt=csv

Example Header For Horde Contacts

I have not used this myself, I found it on the forums.

"assistantPhone","birthday","callbackPhone","carPhone","company","companyPhone","email","email2","email3","firstName","fullName","homeCity","homeCountry","homeFax","homePhone","homePhone2","homePostalCode","homeState","homeStreet","homeURL","imAddress1","imAddress2","imAddress3","jobTitle","lastName","middleName","mobilePhone","notes","otherCity","otherCountry","otherFax","otherPhone","otherPostalCode","otherState","otherStreet","otherURL","pager","workCity","work"

I'm hoping the forum user simply renamed the top header column to match description fields that Zimbra knows and that it's in order of the data (left to right) that Horde normally exports in. You'll need to review it and make sure it fits with your exported data columns from Horde.

Admin With Curl And Wget

You will most likely need to include :7071 in the url string to get around the pop-up issue that you would get if you used the same string in a web browser, without :7071 you'll see a permission error when trying to see/get data from a users account via the admin account.

curl -u admin:pass https://hostname:7071/home/user/Contacts
wget https://admin:pass@hostname:7071/home/user/Contacts

What's My Server Like

To dump out your server details, these commands are useful. Login to your zimbra server and as the zimbra user do:

zmprov gs `zmhostname`
zmprov gacf
zmlocalconfig
zmdumpenv

Another good document to review for "odd performance" issues is the large server wiki.

http://wiki.zimbra.com/index.php?title=Performance_Tuning_Guidelines_for_Large_Deployments

Restarting Jetty - ZCS 5+

As zimbra

zmmailboxdctl restart

How Do I Find Out What Version Of Zimbra I'm Using

See:

Get Version From Ajax Client

In newer versions of ZWC, the Help > About will also state the ZCS server version being used.

For older version, put the below in the search field of the Ajax client and hit enter:

$set:get version

Also:

https://SERVERNAME/js/zimbraMail/share/model/ZmSettings.js

Search for the CLIENT_VERSION line.

Other Ways To Get Version Of Server

See this forum post:

What's Compiled With Postfix

Moved to What's_Complies_With_Zimbra's_Postfix

REST Information

Resources to review

Format to get around permission denied on multi-domain hosting servers

If you getting permission denied rather than resource not found...try this format example:

http://MAILSTOREofUSER.DOMAIN.com/zimbra/user/FIRST.LAST@USERS_DOMAIN.com/inbox.zip

or

http://MAILSTOREofUSER.DOMAIN.com/zimbra/user/USERNAME@USERS_DOMAIN.com/inbox.zip

I but both in case one issue is where the username has special characters, like the period.

Server Source Doc's

Please see:

http://svn.sourceforge.net/viewvc/zimbra/trunk/ZimbraServer/docs/


Jump to: navigation, search