Cannot connect to Perforce server via visual client - windows

I set up a new Perforce free service on my home server. I am able to connect to the service on the same machine using the visual client targetting localhost:1666. When I try to connect from my desktop I am unable to connect. I originally tried my public IP which is forwarded to my server, but when that didn't work I tried targetting my server locally as Server: "192.168.1.105:1666" In either case I get a similar error of:
Connect to server failed; check $P4PORT.
TCP connect to 192.168.1.105:1666 failed.
connect: 192.168.1.105:1666: WSAETIMEDOUT
On my server "p4 set" shows:
C:\Users\Hephaestus>p4 set
P4EDITOR=C:\Windows\SysWOW64\notepad.exe (set)
P4PASSWD=13C72FC3B6AE5DF224D835D7A26332A0 (set)
P4PORT=1666
P4ROOT=D:\p4
P4USER=Hephaestus (set)
P4_1666_CHARSET=none (set)
On my desktop "p4 set" shows:
P4EDITOR=C:\Windows\SysWOW64\notepad.exe (set)
P4PORT=50.137.244.199:1666 (set)
P4USER=jelamb (set)
I've also worked through most of this: http://answers.perforce.com/articles/KB/2960/. I tried turning my server's firewall off completely.
I've spent hours trying to figure this out and I'm just stumped. Why would I be unable to connect?

I ended up finding out that for whatever reason, adding the config stuff as system variables through Windows didn't do what I needed. Adding them via p4 command-line commands did the trick. Weird, but it works now :/.

Related

SQLPlus is throwing client hostname issue ORA-24454, whereas I can telnet to hostname successfully

I'm trying to connect to the oracle database via sqlplus hosted on a remote instance using command like this sqlplus user#hostname.com:port/SchemaName. And on typing password it throws weird client host issue. See the screenshot below.
The question is which host name its expecting me to put inside /etc/hosts?
Whereas I can telnet successfully to same instance without any issues. By the way I'm on MacOS 10.15.7.
Oracle clients were installed using this link. Can be seen from the screenshot below.
The installation was moved to the appropriate folder.
The $PATH was also exported to ~/.bash_profile file
I was able to resolve this issue by the solution mentioned on this link.
Using hostname command I was able to find host name of my machine, which was required to make a successful connection to the Oracle.
The screenshot below explains the process
The hostname entry looks like below

Kubernetes on Windows Error: Unable to connect to the server: dial tcp some ip

I have downloaded Docker and then enabled Kubernetes on the Desktop. When I execute 'Kubectl version' command on the PowerShell it says:
kubectl : Unable to connect to the server: dial tcp : connectex:
A connection attempt failed because the connected party did not properly respond
after a period of time, or established connection failed because connected host has
failed to respond.
At line:1 char:1
kubectl version
The same issue started to occur today when I run anything related to kubectl on Windows. However, it previously worked fine. Maybe there are some recent updates in Windows/Docker.
UPD
Actually, my network sharing options were reset for some reasons. Please try the solution described below (works for me)
SOLUTION:
Check your Network and Sharing settings:
Control Panel > Network and Sharing > [YOUR_NETWORK] (For me it's my Wi-Fi connection) > Properties > Sharing
On the Sharing tab make sure that you have all checkboxes checked and that you selected the correct virtual network in the "Home network connection" field. If not, please use the correct one.

Mulesoft - SFTP Component to go through SOCKS Proxy

I was hoping someone could help.
I am trying to sftp to a remote server that is behind a firewall. I have a proxy setup and can sftp via the unix terminal succesfully. However when using mulesofts SFTP connector I get a timeout. From research it looks like this is because it is run on the JVM.
Mule comes with wrapper.conf to update any jvm settings so I have set the following settings:
wrapper.java.additional.15=-DsocksProxyHost:hostname
wrapper.java.additional.16=-DsocksProxyPort=1080
When I do this the Mule service no longer runs and get the following error:
WrapperManager Error: Unexpected exception opening backend socket: java.net.SocketException: Can't connect to SOCKS proxy:Invalid argument or cannot assign requested address
Hopefully someone can assist.
Thank you.
Perhaps typo in the
-DsocksProxyHost:hostname
Should be = rather than :.
The port is unnecessary, 1080 is the default. Documentation is here, see section 2.4 for SOCKS
http://docs.oracle.com/javase/8/docs/technotes/guides/net/proxies.html

windbg, cdb unable to query for remote debugging server

I have no trouble running dbgsrv on one machine, and then from another machine using cbb to attach to the remote session with
cdb -premote tcp:server=ipaddress,port=port process
However for some reason I can't make
cdb -QR ipaddress
work to show the server. Even with the server running on the same machine, firewall off, running
cdb -QR 127.0.0.1
returns
Unable to query 127.0.0.1
Similarly windbg > Connect To Remote Stub > Browse also fails to return anything.
Also, while I can connect to the remote session using
windbg -premote tcp:server=ipaddress,port=port process
I can't use windbgs "Connect to remote stub" to connect to the very same session using connection string
tcp:server=ipaddress,port=port process
Any idea what is causing me to not be able to query for server sessions? Also why can I connect from the command line, but not from within windbg using Connect To Remote Stub?
P.S. This should probably also be tagged dbgsrv, but there is no such tag.
P.P.S. The reason I want to use dbgsrv rather than .server command is that I want to resolve symbols and source on my local machine.
The correct syntax is cdb -QR \\127.0.0.1
When using windbg > Connect To Remote Stub > Browse, Enter the IP address of the computer you want to browse in the Machine field before clicking on Refresh

Using oracle db through ssh tunnel. Error "ORA-12541: TNS:no listener"

Hello I've got a problem accessing Oracle DB from our datacenter through a tunnel.
We've got a pretty standard datacenter with one machine being accessible from the outside
(I put it's IP in the /etc/hosts file as dc) and the Oracle DB inside. The IP address of our oracle database on internal network is 192.168.1.7
To create a tunnel I'm using the command:
ssh -L 1521:192.168.1.7:1521 root#dc
and of course it works (sometimes I also add some debug -vv to see if anything is passing through).
Now the difficult part - connecting to Oracle. I installed instantclient 11.2. and my tnsnames.ora looks like that:
testdb =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = dbname)
)
)
And when I try to connect using the command:
./sqlplus username/pass#testdb
It starts connecting through the tunnel (I see it in the ssh debug) but then it fails
telling:
./sqlplus username/pass#testdb
SQL*Plus: Release 11.2.0.1.0 Production on Wed Jan 13 20:46:07 2010
Copyright (c) 1982, 2009, Oracle. All rights reserved.
ERROR:
ORA-12541: TNS:no listener
Enter user-name:
When I'm trying to execute this same command on when I'm on the intranet it works (obviously the only difference is that in the tnsnames.ora HOST we have 192.168.1.7 and not the localhost).
I also tried to use the simple command line:
./sqlplus username/pass#//localhost:1521/testdb
or alternatively
./sqlplus username/pass#//localhost:1521/testdb
But nothing helped :)
I would appreciate any help or suggestions. Am I missing some ssh flag to make it possible?
Probably the log file:
***********************************************************************
Fatal NI connect error 12541, connecting to:
(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=DBNAME)(CID=(PROGRAM=sqlplus#velvet)(HOST=velvet)(USER=johndoe))))
VERSION INFORMATION:
TNS for Linux: Version 11.2.0.1.0 - Production
TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.1.0 - Production
Time: 13-JAN-2010 20:48:42
Tracing not turned on.
Tns error struct:
ns main err code: 12541
TNS-12541: Message 12541 not found; No message file for product=network, facility=TNS
ns secondary err code: 12560
nt main err code: 511
TNS-00511: Message 511 not found; No message file for product=network, facility=TNS
nt secondary err code: 111
nt OS err code: 0
where velvet is my local hostname and johndoe is my local username.
Why is it sent to the other side?
UPDATE:
After investigating a little bit more from inside datacenter and it looks like:
- the first connection is going to the port 1521
- but then sqlplus is redirected to the port number > 3300, which is different everytime and incrementing by 3 (at least few tries I had)
- when we are trying to connect trough a tunnel sqlplus will try to connect to localhost and it will obviously fail
So the error "No Listener" comes probably from the fact that we are not redirecting those ports. Is there any way (probably some option in tnsnames.ora file) to force some specific port to be used?
Look into Metalink ID 361284.1 (Edit: effectively not public, but find the info here)
It seems like Oracle Connection Manager would be your option. It basically handles the port redirects inside the firewall. I haven't used it before, so cannot advise you further.
Update: Another way to go would be to use MTS, configure dispatchers with certain ports and open these ports in the firewall. You wouldn't have to install additional software for this, but connecting through shared server may require increasing LARGE_POOL_SIZE, among other considerations. So you'd still need the DBA role to change the DISPATCHERS parameter. You'd also have to bounce the DB.
Normally this should work. I would not use a default listener port as an entry for the ssh tunnel but that should not be the problem. I would also not user the root account to create the ssh connection, preferably a dedicated regular account. Are you using shared servers or does the database happen to be a RAC database with a load balance configuration?
A nice explanation is here How can I connect to ORACLE DB through ssh tunnel chain (double tunnel, server in company network) ?, a bit more complicated .....
update
checkout DbVisualizer, it now has integrated ssh tunneling. I think it is worth to al least give it a try. It's not free but good. Multi platform and multi database and very flexible.
In my case the problem is that the DB server has several IPs and when I used SSH tunnel it was connecting to wrong different one.
So try to check, if the destination IP is the same as the IP in the listener.ora file on the DB server.
Can you try to make a trace to determine exactly what is happening:
For server trace, try here (be carefull! all the new request will be traced and the server can be collapsed).
For client trace, checkout here.
MJ! Your tunnel is only for the initial tcp connect, your own LISTEN port is not tunnelled, and probably unimplemented. Firewall should allow a connect back to you, similar to active FTP.
All ports for Oracle are documented quite extensively starting page 670 of "Building Internet Firewalls" 2/E Chapter 23, paragraph: Oracle SQL*Net and Net8. You can view it on SafariBooksOnline.com
ISBN 1565928718
Perhaps your listener haven't been started yet. Try run "lsnrctrl start" command.
Also a good explanation is here connection to an oracle database though a SSH secure shell which worked for me.
Open putty and on the session page, enter the name of a server and make sure SSH is checked. The server can be any server that you have a
username and password to login with. I use one here called BLUEBIRD as
I own it!
On the connection->ssh->tunnels page, uncheck both options at the top ("Local ports accept ..." and "Remote ports do the same").
Enter 9999 (or any port above 1024 as the Source Port.
In the destination, enter the database host and port as per tnsnames. In my case, this is a server called GREENBIRD and a port of
Enter this as server:port.
As the port being forwarded is on your desktop, check the "Local" option. Leave "Auto" checked as well for the IP version.
Click the Add button. You will see L9999 greenbird:1521 (your will differ) in the list of forwarded ports.
Go to the session page again, Enter a name for your saved session and click save.
Click open. Supply a username and password for the server (BLUEBIRD in my case). You will login a normal ssh session to the server named
BLUEBIRD.

Resources