發表文章

LDAP query

mail enalbed + user only + account enabled (&(mail=*)(!(objectclass=contact))(!(userAccountControl:1.2.840.113556.1.4.803:=2)))

Create Enterprise CA for Apach

圖片
1. install openssl on Linux     apt-gete update     apt-get install openssl 2. openssl -genrsa -out aaa.com.key 2048 3. openssl req -new -sha256 -key aaa.com.key  out aaa.com.csr     Country Name:     State:     Org:     OU:     Common Name:     Email Address: 4. make sure there are 2 files under the folder - aaa.com.key & aaa.com.csr 5. cat aaa.com.csr the copy red square part 6. paste it to Enterprise CA web portal  (https://aaa/certsrv/en-us) 7. choice as web server certificate 8. download aaa.cer and aaa.p7b 9. upload both file to Linux 10. openssl x509 -inform der -in aaa.cer -out aaa.pem 11. modify config file under /etc/apache2/site-available

Update VCSA 6.x patch

圖片
1. Mount iso file on VCSA , iso file should download from VMware    https://my.vmware.com/group/vmware/patch 2. Logon VCSA who with Administrator role. 3. run "software-packages install --iso"

Linux VDI support 4K monitor

Linux RD VDI machine, the scaling issue is fixed. svga.vramSize = "268435456" svga.autodetect="false" modify svga.maxHeight="2048"  to svga.maxHeight="3200"   and keep svga.maxWidth="10240" after that, I also add keyboard.typematicMinDelay = "2000000" 

WinSCP Connection to VCSA failed – “Received too large SFTP packet”

圖片
Logon VCSA and logon shell then input below command chsh -s /bin/bash root After complete SCP, use below command to rollback setting chsh -s /bin/appliancesh root

How to build PrivacyIdea HA with MySQL with master and master replication

1. Install PrivacyIdea on 1st Privacyidea Refer: https://www.youtube.com/watch?v=YzQPA3fQuYQ Add repository on Ubuntu #add-apt-repository ppa:privacyidea/privacyidea Update apt #apt-get update Check apt cache has privacyidea # apt-cache search privacyidea Install 2FA system. This is a meta package to install privacyidea with apache2 + MySql #apt-get install privacyidea-apache2 Create admin account and set password #pi-manage admin add admin admin@localhost Install 2FA FreeRadius  # apt-get install privacyidea-radius Install 2FA everything # apt-get install privacyidea-all 2. Install PrivacyIdea on 2nd Privacyidea  3. Setup Mysql master to master replication Refer: https://www.digitalocean.com/community/tutorials/how-to-set-up-mysql-master-master-replication ********************************************* Primary my.cnf bind-address            = xxx.xxx.xxx.xxx server-id            ...

Migrate VMware Horizon View Persona profile from Windows 7 to Windows 10

migprofile.exe /s:\\file02\share\profiles\*.v2 /v2tov6 /takeownership

VMware Instant Clone Push Image Flow

Just make a note for remind how to Push Instant Clone VM Update master image take snapshot Logon Horizon View Administrator portal Go to Instant Clone pool \Summary\ Push image Select snapshot you want push Below are automatically Clone a template VM from master image Power on tempalte VM Power off template VM Create a snapshot on template Clone tempate VM to Replicate VM vCenter check digest Replicate VM create snapshot Delete Old VDI VM Deploy new parent VM on each host Depliy new VDI VM Power off old parent VM Delete old parent VM

Windows 7 SP1 + Instant Clone

If your deploy Windows 7 SP1 + VMware Instant clone, you have to install microsoft hotfix to avoid deploy failed.   https://support.microsoft.com/kb/2550978

HP SMART ARRAY CLI COMMANDS ON ESXI

HP SMART ARRAY CLI COMMANDS ON ESXI Show configuration /opt/hp/hpssacli/bin/hpssacli ctrl all show config Controller status /opt/hp/hpssacli/bin/hpssacli ctrl all show status Show detailed controller information for all controllers /opt/hp/hpssacli/bin/hpssacli ctrl all show detail Show detailed controller information for controller in slot 0 /opt/hp/hpssacli/bin/hpssacli ctrl slot=0 show detail Rescan for New Devices /opt/hp/hpssacli/bin/hpssacli rescan Physical disk status /opt/hp/hpssacli/bin/hpssacli ctrl slot=0 pd all show status Show detailed physical disk information /opt/hp/hpssacli/bin/hpssacli ctrl slot=0 pd all show detail Logical disk status /opt/hp/hpssacli/bin/hpssacli ctrl slot=0 ld all show status View Detailed Logical Drive Status /opt/hp/hpssacli/bin/hpssacli ctrl slot=0 ld 2 show Create New RAID 0 Logical Drive /opt/hp/hpssacli/bin/hpssacli ctrl slot=0 create type=ld drives=1I:1:2 raid=0 Create New RAID 1 Logical Drive /opt/hp/hp...

NetApp C-mode check node system statistic

1. Logon cluster IP 2. #set diag 3. #node run -node nodename sysstat -M 1

NetApp Harvest + NetApp 7-Mode

Here is configuration need to apply on 7-mode. useradmin role add role-harvest -c "Role for performance monitoring by NetApp Harvest" -a login-http-admin,api-system-get-version,api-system-get-info,api-perf-object-*,api-ems-autosupport-log useradmin group add group-harvest -c "Group for performance monitoring by NetApp Harvest" -r role-harvest useradmin user add netapp-harvest -c "User account for performance monitoring by NetApp Harvest" -n "NetApp Harvest" -g group-harvest options tls.enable=on

Event Log Query value is '%%1537'

Append Red high light in end <QueryList> <Query Id="0" Path="Security"> <Select Path="Security">*[System[(EventID=4663)]]and *[EventData[Data[@Name='AccessList'] and (Data='%%1537 &#xD;&#xA;&#x09;&#x09;&#x09;&#x09; ')]]and *[EventData[Data[@Name='AccessMask'] and (Data='0x10000')]] </Select> </Query> </QueryList>

Linux Xterm color change

xterm -fn 8x13 -bg black -fg green -geo 150x50 -sl 3000 &

Windows 2012 R2 logon error "The User Profile Service service failed the sign-in"

圖片
Error : When you get "The User Profile Service service failed the sign-in, User profile cannot be loaded" Solution : check C:\Default security tab, if no " NT Authority\Authenticated Users" with Full Control permission, please add it.

Update X710 firmware

Go to the below website and download the update utility. https://downloadcenter.intel.com/download/24769#help You will want the XL710_NVMUpdatePackage_v5_04_ESX.tar.gz Copy this onto a datastore accessible by the ESXi server and extract with the command  tar -zxvf  XL710_NVMUpdatePackage_v5_04_ESX.tar.gz [root@coloesx25:/vmfs/volumes/dd478478-16edd549/XL710/ESXi_x64] chmod 755 nvmupdate64e [root@coloesx25:/vmfs/volumes/dd478478-16edd549/XL710/ESXi_x64] ./nvmupdate64e Intel(R) Ethernet NVM Update Tool NVMUpdate version 1.26.17.11 Copyright (C) 2013 - 2016 Intel Corporation. WARNING: To avoid damage to your device, do not stop the update or reboot or power off the system during this update. Inventory in progress. Please wait [******+...] Num Description                            Device-Id B:D   Adapter Status === ====================================== ========= ===== ==...

Linux network rules.

networking rule - /etc/udev/rules.d/70-persistant-net.rules and edited the mac address of eth0 there

Active Directory - Use AD Recycle Bin

Active Directory - Use AD Recycle Bin Windows Server 2008 R2 Active Directory includes a feature called the Active Directory Recycle Bin that will allow administrators to restore deleted objects without having to perform an administrative restore. Campus Active Directory has the AD Recycle Bin enabled. The example PowerShell commands bellow can be used to list and restore deleted objects. List Deleted Objects: Get-ADObject -f {isdeleted -eq $true } -includeDeletedObjects -pr * | ft Name,lastknownParent,objectClass Restore a single deleted object: Get-ADObject -f {(isdeleted -eq $true) -and (name -eq )} | Restore-ADObject -identity Restore multiple deleted objects (objects that have a name that ends with "smith"): Get-ADObject -f {(isdeleted -eq $true) -and (name -match "*smith")} -includeDeletedObjects -pr * | restore-adobject Technical Details The amount of time that an object can be recovered is controlled by the Deleted Object Lifetime (DOL). By d...

[Horizon View]How to configure RHEL 6.7 for vDGA

圖片
1. Enable DirectPath I/O for NVIDIA GRID GPUs on a Host 2. Power off  virtual machine and Add a vDGA pass-Through Device to a RHEL 6.7 Virtual Machine.      2.1 Add New device and select PCI Device and click Add     2.2 Select PCI device from the drop-down menu     2.3 Click Reserve all memory     2.4 Click OK     2.5 Power on and to the virtual machine 3. Install NVIDIA Display Driver on RHEL 6.7 and Horizon View Agent     3.1 Disable and blacklist the default NVIDIA Nouveau driver         a. Edit /boot/grub/grub.conf         b. Add  rdblacklist=nouveau line at the end of the module  ( This is different with setting guide )                c. Edit /etc/modprobe.d/blacklist.conf         d. Add blacklist nouveau line anywhere in the blacklist.conf file         e. Restart...

Lync 2013 import and update contact & group

You have to import first and run update on 2nd. Import contact on Lync 2013 with powershell PS C:\Users\xxx\Desktop> import-CsUserData -FileName "C:\Users\xxx\Desktop\20160108-TW.zip" -UserFilter aaa.bb@mediatek.com Update contact on Lync 2013 with powershell PS C:\Users\xxx\Desktop> update-CsUserData -FileName "C:\Users\xxx\Desktop\20160108-TW.zip" -UserFilter aaa.bb@mediatek.com