Thursday, 31 March 2016

how to open student block account for Germany

Opening the block account is very crucial for the Visa process and it is time consuming during peek times. There are three ways students can open the block account.

1. In Deutsche Bank in Germany through Embassy.
2. In Local Deutsche Bank
3. In Kotak Mahindra Bank.

Select the first option always, in worst case go for the other options.


1.In Deutsche Bank in Germany through Embassy.

Steps:
       1. Book an appointment in German consulate Click Here
       2. Carry filled application form and passport copy to embassy, they will attest both the copies.
       3. Send the attested copies to Deutsche bank address which is mentioned in the application                      form.
       4. You will get response with in 10 working days.

2. In Local Deutsche Bank.

Steps:
  1. Go to any nearest Deutsche bank along with passport copy,pan card and one cheque for 1 lack rupees.
  2. They will fill both savings account form and block account form and send the block account form to Germany.
  3. they open savings account within 7 working days and you need to maintain the minimum balance of 1 lack rupees.
  4. The wont be having any control on the block account opening once they send the application.You can save the courier charges and attestation charges. But you need one lack rupees.

3. In Kotak Mahindra bank.

Steps:
  1. You need to carry cheque for rupees equivalent to 8500EUROS to any nearest kotak mahindra bank, they will open block account with in 3 to 10 working fays.
  2. once you reach Germany you need to open an block account in Deutsche bank again.

Note: open the block account while you are applying for universities, during the peak times this is the time consuming process and it holds visa process. It does not require university admit letter.



Tuesday, 24 December 2013

shell script to check mount point size in linux/solaries

The following shell script notifies you if any mount point is greater than 90% full
#!/bin/bash
df -h |tr "%" " " |sed -n '2,$p'| awk '{

if ( $5 > 90 ) {print $6,echo "filesystem is greater than 90% full";}

}'

Output will be something like below.
/orahome1 filesystem is greater than 90% full

Friday, 20 December 2013

Unix questions and answers.

1. creating zero lenght file.
$cat /dev/null >file.txt

2. to find teh file size greater than 1000bytes.
$find ./ -size +1000

3. switching a shell
csh -s /bin/csh

4. adding user in linux.
$useradd -d /root/user1 -g owner -s /usr/bin/csh -m user1
$passwd user1

5. delete user in linux.
$userdel -r username

6. check the network status.
$netstat -ef | grep 2000

7. to configure the network status.
$ifconfig

8. display al running jobs.
$top

9. bring job to the foreground
$fg %jobnumber

10. bring the job to background.
$bg %jobnumber.

12. convertin file from dos to unix.
$dos2unix filename

13. split command
$split -option sourcedfile destinationfile
         - b bytes
         - l number of lines

14. deleting empty lines.

$sed '/s/^$/d' inputfile >outputfilee

15. creating symbolic link.
$ln -s file link

16. locate all instnce of the file.
locate file

17. to check disk space.
$df -options
        -k  kilobytes
        -m meghabytes
        h human readable

18. to get all teh links.
$ls -lrt | grep"^l"

19. display the output to multiple files.
$data | tee file1 file2

Linux important commands.

1. Display the utilization of each CPU individually.
$mpstat -P all

2. display the top 10 process which consume CPU.
$ps -eo pcpu,pid,user,args | sort -k 1 -r | head -r

3. display hte memory details.
$cat /proc/meminfo

4. display the memory usage.
$free -m
$vmstat

5 display the number of cpu.
$cat /proc/cpuinfo | grep processor | wc -l
6. display the shared memory parameters.
$ipcs -m

7. display the share memory limits.
$ipcs -lm

8. display the disk activity.
$iostat

9. display the users logged on to the system.
$w

10. display how long the system is running.
$uptime

11. display which shell is using.
$ps -P $$
$echo $SHELL
$echo $$
12. display the awk version.
$awk --version

13. display the page size.
$getconf getsize

14. free the shared memory space.
$ipcs -m     -> it gives the shm id.
$ipcrm <shmid>
$15. memory mapping of the process.
pmap -d pid

16. list all the users.
$cat /etc/passwd

17. display the mounted file system
$cat //proc/mounts

18. to know the swap allocated.
$cat ./proc/swaps

19. display the version of teh kernel.
$cat /proc/version

20 to know whether 32 bit or 64 bit.
$arch
21. to check the available shells.
$cat /etc/shells

Java most asked interview questions

1. what is transient variable?

By default all the variables in the object get converted to a persistant state, in some case you may want to avoid passing some variables, so you can declare that variable as transient variable.
Transient variables are non-serializable.

2. what will happen if we don't initialize the local variables?
COmpilation error will come.

3. Instance variables are initialized to what values?

integer- 0
float 0.0.
boolean - false
string - null.
char -  nothing.

4. how to set locale for Canada?
Locale canada = new Locale("fr","CA");

5. if a exception thrown by a try statement but no catch what is the output?
Compilation error.

6. which variable is synchronizes?
a.static
b.public
c. private

Ans:static.

7. which is the default access specifier for class?

Package

8. JVM declare how many times of memory?

stack and the heap memory.

9. what is the deamon process and whether we can ceate the deamon process?
Deamon process is the thread which is the service provider for user threads.
which will terminate after all user threads terminated.

Yes, we can create the deamon process using
setDeamon() method.

and can check isDeamon().

we need to create the deamon thread before calling the start() method.

10. what is singleton class?
we can not initialize more than one instance.

11. why implementing the runnable interface preferable over extend the thread?
thread class
a. If we extend the thread class all the threads create their own objects and associated with them.
b. if we extend thread in future we can not extend any other thread.

runnable interface.

a. we can implemetn any number of interface.
b all threads created will share same object spce.

11. which algorithem used in java garbage collection?
mark and sweep algorithem.

12. stack is faster or heap?

stack.

13. what is run time polymorpison.?
binding happens during run time, this is because of method overriding.

14. how many public classes can be present in one java file?

one class.

16. how many main mehods can be present in single java file?

more than one.

17. difference between ennumaration and Iterator?

Ennumaration.
It is read only.
it does not have remove method.

Iterator.
It can modify the collection using remove method.
it does remove methd.

18. difference between hashmap and hashtable?
hashmap.
Allows null keys and null values.
hash map is not synchronized.

hashtable
It does not allow null keys and null values.
hash table is synchronized.

19. Advantages and disadvantages of static bllock?

 Advantages.
a. used while loading the device driver.
b. for initialize the variables which requires computation.
c. security related and leaking issues.

disadvantages.

a. static initialization block should not exceed 64k.
b. cn not through checked exceptions.
c. should not try to access super since there is no such thing for static block.
 d. can not return anything from static block.

20.why interface is better than abstract class?
 java will not support class multiple inheritance  so interface is usefull.

21. what is early binding?

the data and the method which will operate on the data are separately  defined in oops, and they bind data members during compilation time.

22. difference between multi threading and multi processing?
multi threading.
a. shares same address space.
b. thread is light weight.
c. cost of communicartion is low.
d. context switching cost is very less.


multi process.
a. each process have seperate address space.
b. heavy weight component.
c. coat of intercommunication is high.
d. context switching cost is very high.

23. why jvm is platform dependenant.
JVM is developed usig the platform dependent languages like c,c++ so it is platform depedent.

24. difference between classpath and path environmen variables?
classpath referes to the user clasess whre located.
c:/programs/
path refers to the executable where located.
c:/java/jdk/bin



 





Java interview questions.

Monday, 23 July 2012

top 10 engineering colleges in bangalore

1, RV college of engineering.
2. People education society institute of technology(PESIT).
3.BMS college of engineering.
4. Univercity of vishveraiah college of engineering(UVCE).
5.Bangalore institute of technology(BIT).
6.M S Ramaiah institute of technology(MSRIT).
7.Dayananda sagar college of engineering.
8.Sr M Vishveraiah institute of technology.
9.C M R institute of technology.
10.MVJ college of engineering.

displaying only duplicate rows in oracle

select id,name,salary  from employee
group by(id) having count(*) >=2;

DB import, export and DB load commands in Informix

DB Export:
dbexport database name [-o dir]
example:
dbexport sysdbs -o tmp
DB Import:
dbimport [-d dataspace] [-dir] database
example:
dbimport -d workdbs - tmp sysdbs

dbload  command:

dbload [-d database] [-c commandnfile] [-l error log] [-n number of rows after commit] [-e number of rows discarded]

command file:
unlfile *,unl delimiter number of fields;
insert statement;
example:
unlfile a.unl delimiter "|" 10;
insert into employee;

dbload -d sysdb -c a.unl -l error.log -n 100 -e 100

Saturday, 21 July 2012

Escape seqence in oracle queries

In oracle database queries '&' has special meaning, while inserting values to table if we give & symbol it will prompt for the input.
example:
insert into employee values(&id,&name,&salary);
It promptsn to enter those values.

If & symbol is there inside the column value then also it will prompt so to avoid that we use escape symbol.
example:
insert into employee(id,name,emil) values (12,'abcd&efg',xyz.gmail.com);

it will prompt like enter efg value. So to avoid this we use escape '\'
insert into employee(id,name,email) values(12,'abcd\&efg',xyz.gmail.com);