Samba CIFS mounts and securing user password

October 15, 2017 Leave a comment

Adding the code blocks below to /etc/rc.local:

mount.cifs //<host1>/share /<mount_point> -o ro,credentials=/root/.cifs.<host1>,remount

Option “remount” prevents double mounting of the same share.

File .cifs.<hostname> contains:

user=<user>
password=<password>
domain=<domain>

Advertisements
Categories: Linux, Redhat, Uncategorized

RHEL 6 IGMPv3 setting

August 11, 2017 Leave a comment

Set following parameter in /etc/sysctl.conf file for the interface that is desired (e.g. bond0, eth0, etc.).

net.ipv4.conf.eth0.force_igmp_version=3
  • Reboot system
Categories: Linux, Redhat, Uncategorized

Prolific USB-Serial Windows 10 Error 10

July 27, 2017 Leave a comment

For this driver to work, you must have the version installed below:

Capture

Categories: Windows

Vagrantfile

Working vagrantfile I want to keep as a sample template:

 

# -*- mode: ruby -*-
# vi: set ft=ruby :
VAGRANTFILE_API_VERSION = “2”
Vagrant.require_version “>= 1.7.2”

# All Vagrant configuration is done below. The “2” in Vagrant.configure
# configures the configuration version. Please don’t change it unless you know what
# you’re doing.
Vagrant.configure(2) do |config|

config.vm.box = “<user>/openshift-origin”
#uncomment this line if you downloaded the box and want to use it instead
#config.vm.box = “openshift3”
config.vm.box_check_update = false
config.vm.network “private_network”, ip: “10.2.2.2”
config.vm.synced_folder “.”, “/vagrant”, disabled: true
config.vm.hostname = “origin”
# Create a forwarded port mapping which allows access to a specific port
# within the machine from a port on the host machine. In the example below,
# accessing “localhost:8080” will access port 80 on the guest machine.
# config.vm.network “forwarded_port”, guest: 80, host: 8080
#config.vm.network “forwarded_port”, guest: 80, host: 1080
#config.vm.network “forwarded_port”, guest: 443, host: 1443
#config.vm.network “forwarded_port”, guest: 5000, host: 5000
#config.vm.network “forwarded_port”, guest: 8080, host: 8080
#config.vm.network “forwarded_port”, guest: 8443, host: 8443

config.vm.provider “virtualbox” do |vb|
# vb.gui = true
vb.memory = “8192”
vb.cpus = 2
vb.name = “origin-1.1.2”
end

end

Categories: Uncategorized

Finding exact SCNs for Oracle Incomplete Restore

Using reference from goldparrot below really helped:
https://goldparrot.wordpress.com/2011/05/16/how-to-find-exact-scn-number-for-oracle-restore/

2) Get the greatest of either absolute_fuzzy_change# or checkpoint_change# for your datafile backups.

The quickest way to roll forward just beyond the backup to open resetlogs is
to query v$backup_datafile.
You then just need to choose the greatest of either the absolute_fuzzy_change# or checkpoint_change#
for your backupset.

You can modify the query to your liking, and even add in many details from stamp and recid, but below
gets the job done quickly. Just choose the day in which your level0 or level1 completed and modify appropriately.

=============================================
` col fuzz# format 99999999999999999999999999
` col chkpnt# format 99999999999999999999999999

select max(absolute_fuzzy_change#) fuzz#, max(checkpoint_change#) chkpnt# from
(select file#, completion_time, checkpoint_change#, absolute_fuzzy_change# from v$backup_datafile
where incremental_level = 0
and trunc(completion_time) = to_date(‘JUN-20-2010′,’MON-DD-YYYY’)
and file# <> 0
order by completion_time desc
);
===============================================

This will return 2 SCN numbers. Pick the greatest of the 2.

FUZZ# CHKPNT#
——————– ——————–
23138984359 23138974759

Categories: Oracle, Uncategorized

Linux testing disk speed with dd

April 21, 2017 Leave a comment

Best way is to use dd and try the following:

dd bs=1M count=256 if=/dev/zero of=test conv=fdatasync

“fdatasync” tells dd to write physically to disk before providing the output. Increase to 1024, 2048 if you want 1G or 2G file size. Bigger sizing will produce a more normalized speed.

Categories: Linux, Redhat

RHEL increasing size of LVOL after LUN expansion

March 6, 2017 Leave a comment

Quick steps (validated on RHEL 5.x) on expanding your lvol when the underlining LUN has been expanded.

Ensure first you have rescanned the scsi devices to pick up on the physical changes to the LUNs. Next, from multipath you should be able to see that the LUN indeed have been expanded. In this case, the new size is 3.5T, original size was 3.0T.

# multipath -ll

vgnetapp1 (3600a09803830344a503f464a4d302f41) dm-3 NETAPP,LUN C-Mode
size=3.5T features=’1 queue_if_no_path’ hwhandler=’0′ wp=rw

Next, the pv has to be resized:
# pvresize /dev/mapper/vgnetapp1

Now, resize the lvol:
# lvresize /dev/mapper/vgnetapp1-lvol1 -l +100%FREE

Finally, resize the underlying filesystem on the lvol:
# resize2fs /dev/mapper/vgnetapp1-lvol1

Expect this to take several minutes depending on the size of your LUN. Run “df -h” to see this operation has indeed increased the lvol and filesystem size. Note, you can run these commands while the LUN is mounted. No need to “umount” at all.

Categories: Linux, Redhat