vi /root/.bashrc
myname=`who am i | awk '{print $1}'` PROMPT_COMMAND='history -a >(logger -p local2.info -t "$myname $USER[$PWD] $SSH_CONNECTION")'
vi /etc/rsyslog.conf
$umask 0000
$FileCreateMode 0666
local2.info /var/log/usercommands
$umask 0077
Notes to myself
vi /root/.bashrc
myname=`who am i | awk '{print $1}'` PROMPT_COMMAND='history -a >(logger -p local2.info -t "$myname $USER[$PWD] $SSH_CONNECTION")'
vi /etc/rsyslog.conf
$umask 0000
$FileCreateMode 0666
local2.info /var/log/usercommands
$umask 0077
In my latest project (API endpoint based on Symfony and api-platform), I have the task to optimize and automate CI/CD processes. As a result: here is super-simplified version of the resulting GitLab pipiline:
Continue reading “CI/CD Symfony 4 with GitLab”
/etc/rc.local
1 |
screen -d -m /home/mdt/project1/scripts/run_workers.sh |
/home/mdt/project1/scripts/run_workers.sh
1 |
su mdt -c '/home/mdt/project1/app/console supertag:gearman:run-worker --env=prod 2>&1 | while read line; do echo `/bin/date` "$line" >> /home/mdt/project1/app/logs/worker.log; done' |
1 2 3 4 5 |
$allVMs = get-vm foreach ($VM in $allVMs) { Enable-VMReplication $VM -ReplicaServerName lasthope.contoso.com -ReplicaServerPort 443 -AuthenticationType Certificate -CertificateThumbprint 87c4337a097b33afb013a9c9001e4eb23fdde321 -ReplicationFrequencySec 900 Start-VMInitialReplication $VM.name } |
If you have error like this:
1 |
ERROR 2015-08-25 13:33:54,601 Controller.py:143 - Cannot register host with not supported os type, hostname=h2.hadoopxyz.abc, serverOsType=ubuntu14, agentOsType=ubuntu14 |
You have to edit :
1 2 |
mc -e /usr/lib/ambari-server/lib/ambari_commons/resources/os_family.json mc -e /usr/lib/ambari-agent/lib/ambari_commons/resources/os_family.json |
And change version number:
1 2 3 4 5 6 7 8 9 |
"ubuntu": { "distro": [ "ubuntu", "debian" ], "versions": [ 14 ] }, |
We have to recreate repository volume of our RP but I could not find any guidance from EMC site. So I’m documenting my steps here for further usage:
Procedure overview:
On EMC storage:
On RP appliances:
On last cluster member:
On each subsequent appliance:
This is a transcript of console sessions:
Continue reading “EMC Recover Point – how to recreate repository volume”
1. get interface
1 2 3 4 5 6 7 8 9 10 11 |
PS C:\Windows\system32> Get-VMNetworkAdapter -VMName pfs3|fl adapterid,ipaddresses AdapterId : 258ffea6-f8ea-46af-a376-7c2b912fe68e IPAddresses : {200.40.8.103, 200.40.8.100, fe80::215:5dff:fe05:a869} AdapterId : 39aeda55-19b3-403c-9c89-d0bf937a4930 IPAddresses : {200.40.19.243, 200.40.19.252, 200.40.19.17, fe80::215:5dff:fe05:a86a...} AdapterId : e579b3aa-8bc6-4ca0-9c39-3fbb568dd205 IPAddresses : {200.40.19.131, fe80::215:5dff:fe05:a86d} |
2. set VLANs
1 2 |
PS C:\Windows\system32> Get-VMNetworkAdapter -VMName pfs4 |Where-Object {$_.adapterid -eq '5d488e8c-b066-4350-acfb-b4ccc 57a9ee7'}|Set-VMNetworkAdapterVlan -trunk -AllowedVlanIdList 1901-1924 -NativeVlanId 1924 |
C:\Program Files\EMC\SYMCLI\bin>
C:\Program Files\EMC\SYMCLI\bin>cd “C:\Program Files\EMC\ECIM\ECOM\bin”
C:\Program Files\EMC\ECIM\ECOM\bin>TestSmiProvider.exe
Connection Type (ssl,no_ssl,native) [no_ssl]:
Host [localhost]:
Port [5988]:
Username [admin]:
Password [#1Password]:
Log output to console [y|n (default y)]:
Log output to file [y|n (default y)]:
Logfile path [Testsmiprovider.log]:
Connecting to localhost:5988
Using user account ‘admin’ with password ‘#1Password’
########################################################################
## ##
## EMC SMI Provider Tester ##
## This program is intended for use by EMC Support personnel only. ##
## At any time and without warning this program may be revised ##
## without regard to backwards compatibility or be ##
## removed entirely from the kit. ##
########################################################################
slp – slp urls slpv – slp attributes
cn – Connect dc – Disconnect
disco – EMC Discover rc – RepeatCount
addsys – EMC AddSystem remsys – EMC RemoveSystem
refsys – EMC RefreshSystem
ec – EnumerateClasses ecn – EnumerateClassNames
ei – EnumerateInstances ein – EnumerateInstanceNames
ens – EnumerateNamespaces miner – Mine classes
a – Associators an – AssociatorNames
r – References rn – ReferenceNames
gi – GetInstance gc – GetClass
ci – CreateInstance di – DeleteInstance
mi – ModifyInstance eq – ExecQuery
gp – GetProperty sp – SetProperty
tms – TotalManagedSpace tp – Test pools
ecap – Extent Capacity pd – Profile Discovery
im – InvokeMethod active – ActiveControls
ind – Indications menu tv – Test views
st – Set timeout value lc – Log control
sl – Start listener dv – Display version info
ns – NameSpace vtl – VTL menu
chp – consolidated host provider menu
q – Quit h – Help
########################################################################
Built with EMC SMI-S Provider: V4.6.2
Namespace: root/emc
repeat count: 1
(localhost:5988) ? addsys
Add System {y|n} [n]: y
ArrayType (1=Clar, 2=Symm) [1]:
One or more IP address or Hostname or Array ID
Elements for Addresses
IP address or hostname or array id 0 (blank to quit): 10.xx.xx.ab
IP address or hostname or array id 1 (blank to quit): 10.xx.xx.cd
IP address or hostname or array id 2 (blank to quit):
Address types corresponding to addresses specified above.
(1=URL, 2=IP/Nodename, 3=Array ID)
Address Type (0) [default=2]:
Address Type (1) [default=2]:
User [null]: admin
Password [null]: xxxxxxxxx
++++ EMCAddSystem ++++
OUTPUT : 0
Legend:0=Success, 1=Not Supported, 2=Unknown, 3=Timeout, 4=Failed
5=Invalid Parameter
4096=Job Queued, 4097=Size Not Supported
Note: Not all above values apply to all methods – see MOF for the method.
System : //10.xx.ab.ef/root/emc:Clar_StorageSystem.CreationClassName=”Clar_Stora
geSystem”,Name=”CLARiiON+CKM00133801649″
In 12.599952 Seconds
Please press enter key to continue…