Mapping Network drives in Weblogic (Windows)

March 3, 2017

Atheek's Blog

In situations where you need to talk to a remote file system from OSB running in Windows machines, you need to map the remote file system to a local drive letter. This scenario caters for two requirements.

1. When you have your OSB cluster spanning multiple servers and all servers need access to a common file (for read only purpose), it is better to have this file sit in a file share accessible by all machines. An example is when using OSB to connect to MQ as foreign JMS, the .bindings file containing the remote JNDI tree for MQ objects can be placed in a file share.

2. In File integrations where you need OSB to read from or write to an external file system.

OSB’s file transport doesn’t support UNC format names for accessing files. Hence mapping to a drive letter is mandatory. This can be done in at-least…

View original post 424 more words


EM dbconsole not started and giving NET HELPMSG 3547

February 1, 2017

Hi guys,

I had a nightmare after Oracle 10g 10.2.0.3 upgraded to 10.2.0.4. While almost everything else went smooth as expected, the enterprise manager (that we don’t use at all actually) will not start. Spent around 48 hours & more to find a solution and performed almost all suggestions including patching the database with SSL patch provided by Oracle. Finally I landed on the following page to resolve the issues. A minor difference was, I hadn’t had to reload the listener as mentioned with the original post.

Hi Friends, today i face some problem with EM dbconsole in one of my databases are here is the way how i resolved it Database version : 10.2.0.4 standard edition OS version : windows 2003 server wi…

Source: EM dbconsole not started and giving NET HELPMSG 3547


Changing sysman and dbsnmp passwords – It ain’t that easy

February 1, 2017

The Tendjee

And of course it’s not that easy!

Actually this is quite annoying.

I have 2 concerns: Having my backups working properly as well as the DB Console.

But also renew my passwords from time to time.

And here we are sys and system’s passwords are luckily easy to change.

But what about sysman and dbsnmp?

Those are not. Try to change it and you will have your backups stop working, OEM throws in tons of errors and soon you will be asking yourself why the hell you wanted to change those passwords in the first place.

The reason

Sysman user is the schema of the standalone repository of the 10g EM DB Control.

If you have change only dbsnmp password your backups will work and the DB console as well but all the cool graphics that I like to show to our customers will disappear and that’s not cool.
There…

View original post 489 more words


C# (CSharp, C-Sharp) Windows Active Directory last logon

January 7, 2017

Hi guys

Please note, many threads were referred in order to compile the script attached below & all I did was re-arranging in order for better reading/formatting

(And I insure that the script works under following scenarios:

  1. You are a domain administrator
  2. You are administrating Windows 2003 onwards Windows domain
  3. Your puter is connected to the domain network ;)

)

Referenced websites/threads

  1. http://stackoverflow.com/questions/15775264/searching-for-lastlogon-attribute-of-user-in-multiple-domain-servers
  2. https://www.codeproject.com/kb/security/lastlogonacrossallwindows.aspx#_comments
  3. http://codebeautify.org/csharpviewer (for formatting the C# code)

How to test the code

Start Visual Studio (I am using 2013 Professional edition, you can use any of the community editions to test the scripts)

Create a new C# Console Application and name it llogon (else you need to change the namespace name “llogon” according to the name you have chosen for your new project.

Add the following references to your project

  1. “Framework -> System.DirectoryServices”
  2. “Browse and add -> C:\Windows\System32\activeds.tlb”

 

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

//Added by Rajesh

//using System.Management;
//using System.Data;
using System.DirectoryServices;
using System.DirectoryServices.ActiveDirectory;
//http://stackoverflow.com/questions/33274162/the-namespace-of-iadslargeinteger
//ActiveDS namespace
using ActiveDs; // Namespace added via ref to C:\Windows\System32\activeds.tlb
//https://www.codeproject.com/kb/security/lastlogonacrossallwindows.aspx

namespace llogon
{
    class Program
    {
        static void Main(string[] args)
        {
            // Get the root entry
            DirectoryEntry rootDSE = new DirectoryEntry("LDAP://RootDSE");
            string configurationNamingContext =
             (string)rootDSE.Properties["configurationNamingContext"].Value;
            string defaultNamingContext =
             (string)rootDSE.Properties["defaultNamingContext"].Value;
            Dictionary<string, Int64> lastLogons = new Dictionary<string, Int64>();
            // Get all the domain controllers
            DirectoryEntry deConfig = new DirectoryEntry("LDAP://" + configurationNamingContext);
            DirectorySearcher dsConfig = new DirectorySearcher(deConfig);
            dsConfig.Filter = "(objectClass=nTDSDSA)";
            foreach (SearchResult srDomains in dsConfig.FindAll())
            {
                DirectoryEntry deDomain = srDomains.GetDirectoryEntry();
                if (deDomain != null)
                {
                    string dnsHostName =
                     deDomain.Parent.Properties["DNSHostName"].Value.ToString();
                    // Get all the users for that domain
                                   DirectoryEntry deUsers =
                     new DirectoryEntry("LDAP://" + dnsHostName + "/" + defaultNamingContext);
                    DirectorySearcher dsUsers = new DirectorySearcher(deUsers);
                    dsUsers.Filter = "(&(objectCategory=person)(objectClass=user))";
                    foreach (SearchResult srUsers in dsUsers.FindAll())
                    {
                        DirectoryEntry deUser = srUsers.GetDirectoryEntry();
                        if (deUser != null)
                        {
                            // Get the distinguishedName and lastLogon for each user
                            // Save the most recent logon for each user in a Dictionary object
                            string distinguishedName = deUser.Properties["distinguishedName"].Value.ToString();
                            Int64 lastLogonThisServer = new Int64();
                            if (deUser.Properties["lastLogon"].Value != null)
                            {
                                IADsLargeInteger lgInt =
                                 (IADsLargeInteger)deUser.Properties["lastLogon"].Value;
                                lastLogonThisServer = ((long)lgInt.HighPart << 32) + lgInt.LowPart;
                            }

                            // Save the most recent logon for each user in a Dictionary object
                            if (lastLogons.ContainsKey(distinguishedName))
                            {
                                if (lastLogons[distinguishedName] < lastLogonThisServer)
                                {
                                    lastLogons[distinguishedName] = lastLogonThisServer;
                                }
                            }
                            else
                            {
                                lastLogons.Add(distinguishedName, lastLogonThisServer);
                            }
                            string readableLastLogon = DateTime.FromFileTime(lastLogonThisServer).ToString();
                            Console.WriteLine("User: " + distinguishedName + "Last logon: " +readableLastLogon);
                        }
                    }
                    Console.ReadLine();
                }
            }

        }
    }
}

Try the code & if you are stuck somewhere, do let me through the comments. I am working on a WPF C# project for a simple Active Directory Reporter / Asset Management System using WMI. Stay tuned & I will soon post the entire solution here :)

regards,

rajesh

 


Using your DVD as a yum repository on a RPM based Linux

November 19, 2016

Frits Hoogland Weblog

So, you’ve just gotten a fresh installed Linux system with Oracle Linux or Redhat Linux from the sysadmin. And with Oracle Linux you can not use the internet (forbidden by company laws is a common one), or you got Redhat Linux and can not use up2date for some reason. Most of the time, when installing Oracle products I am allowed to use the root account myself during the install. The DVD most of the time is still present in the drive.

You could mount the DVD and use ‘rpm’ directly to install packages off the DVD. If you get an error the rpm package has a dependency, you resolve the dependency, if that depended package has a dependency itself, you resolve that, etc. That’s something you could do. But there is an easier way!

Mounting the DVD

The first task is to mount the DVD again. The installation procedure does…

View original post 478 more words


Asking questions, following them up

November 8, 2016

Hello Guys

Not all situations, however for certain interesting cases, I spend loads of time out of my professional and personal life to nail down the concerns, situations you highlight through the comments and I feel neglected and insulted when YOU don’t respond to my queries on timely manner. No, it doesn’t mean I am not going to respond to your specific questions, however I may not follow up the progresses you have made unless I see a keen involvement.

Further, many instances I contact you through the emails provided with your comments and other than 1-2 instances, I have never received replies. I send you emails to insure that your private information are not being visible through the comments area. Hence, please make sure that you will be using regularly used email accounts while commenting or asking questions.

Please follow the below guidelines if you are keen about getting answered

  • Provide me an email address that you are frequently checking
  • Regularly check for the comment replies (You get a notification on email when I reply to your comment)

If I am not supported by YOU as the initiator, please be informed that, I do have better things to do :)

Sorry for the “Attitude”, however, that is going to save me some precious time!

regards,

 

 


Undernet | random nickname and authentication script

October 18, 2016

 

Copy to a text file, rename the file as anyname.mrc and load with mIRC client

–Code

on *:connect:{
  ;If you doubt someone has you in the notify list
  ;the best way to trick them until you authenticate with X (undernet) and mask your IP address
  ;is to pick a random nick, which will overwrite the last nick
  ;you had during last quit!

  if ($network == UnderNet) {
    ;Change according to the server parameters
    ;for authentication
    ;/nick rtkwt
    /nick $rand(a,z) $+ $rand(1,0) $+ $rand(a,z) $+ $rand(a,z)
    /log off
    /set %auth_username $$?=”Enter User Name” | /set %auth_password $$?=”Enter Password”
    /msg x@channels.undernet.org login %auth_username %auth_password
    /unset %auth_username | /unset %auth_password
    clear
    /log on
    ;Clear command above clears the status window, ie, from prying eyes ;)
    ;make sure status window is not logged
    ; /echo $me
    /mode $me +x
    ;To disable the automatic join, you can either delete it or comment it by using a “;” character.
  }
}