-1

I want to open 5 terminals from a parent terminal and place these terminals on the screen properly so that each terminal can be viewed properly at the same time. Also, i want to execute differnet commands in each terminal.

Can you help me please?

Thanks, pawan

1

2 Answers 2

1

You can use gnome-terminal command to open a new terminal. Also if you want to execute a command in new terminal you can use following command :-

gnome-terminal -e "bash -c 'cat > /tmp/sample'"

This will open a new terminal which will open sample file for writing. You can place your commands or scripts. Also if you want 5 terminals, procedure is same.

4
  • Gnome wouldn't normally be found on a server.
    – user9517
    Jan 4, 2016 at 6:52
  • @lain I know most of servers don't have Gnome installed. Since the question didn't specify any linux distro or method through which he wants to access terminals so I gave a generic answer. If you know some other method than we will appreciate and will learn something new. Jan 4, 2016 at 7:15
  • This isn't a generic answer it's actually quite specific to gnome.
    – user9517
    Jan 4, 2016 at 7:35
  • There's no indication the OP has Gnome and I don't see any question about it in the comments. Plus gnome-terminal is a pain to automate.
    – chicks
    Jan 4, 2016 at 13:49
1

Tmux would be one way to solve your problem. It can open several terminals by splitting the screen & more. This answer at superuser will be helpful.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .