Questions tagged [google-cloud]

For questions relating to the Google Cloud Platform.

Filter by
Sorted by
Tagged with
0 votes
0 answers
13 views

How to attach new terminal with existing process and subprocesses?

I'm trying to us reptyr to reattach new cloud shell to an existing program running on an ubuntu virtual machine. when running sudo reptyr PID I get the following error: Process PID (sudo) shares PID's ...
user avatar
0 votes
1 answer
17 views

gdrive not working on Fedora 35

I would like to access my cloud data on Google Drive from terminal, so I have downloaded gdrive from this source; I have selected gdrive_2.1.1_linux_amd64.tar.gz since I am on Fedora 35 with a 64 bit ...
user avatar
  • 173
0 votes
0 answers
53 views

How can I launch apps or execute terminal commands in an Ubuntu 20.04.3 Docker container running on Google Cloud Run?

I am running an Ubuntu 20.04.3 desktop in the cloud on Google Cloud Run. When I run the container image locally, I can run any process, including a bash terminal. However, on Google Cloud Run, ...
user avatar
  • 255
0 votes
1 answer
78 views

"EOF in backquote substitution" when trying to run a binary file

I get the following error when trying to run a binary file with the command: tmp/123.bin tmp/123.bin: 1: tmp/123.bin: Syntax error: EOF in backquote substitution I have no idea what could be causing ...
user avatar
  • 101
0 votes
0 answers
6 views

How to get the 'Authenticated URL' from multiple Items in a google bucket?

In my google cloud bucket is a folder with a lot of images and i want to extract the Authenticated URL from all images in the folder? With gsutil ls -L "gs://bucketname/path_to_folder/" i ...
user avatar
  • 101
0 votes
1 answer
237 views

Using SCP in a Bastion VM setup with an established SSH tunnel

I am looking at ways to mitigate the potential for using scp commands within GCE VMs that are running CentOS 8. Current setup is a bastion VM being able to SSH into a secondary VM (instance-1). I have ...
user avatar
  • 103
0 votes
0 answers
23 views

Unable to access GCP VM after change in permissions

I was able to access my GCP VM instance until today morning. I had to share VM access to my colleague and I executed chmod -R 777 filename Since then I am unable to ssh into my VM instance. Now as I ...
user avatar
0 votes
0 answers
152 views

Unable to create a new directory in a mounted path on GCP VM

I have a GCP VM instance. A GCP storage has been mounted in that instance. I am unable to create a new directory in that mounted directory. I created the directory using: mkdir gcs I then mounted ...
user avatar
0 votes
0 answers
20 views

Is it common for GCP servers to see continuous timeout in the initial hops?

While doing traceroute from my GCP server to any domain initial hops I am getting timeout also intermittently I get timeout upto last hop. $ traceroute amazon.com traceroute to amazon.com (205.251....
user avatar
0 votes
1 answer
34 views

Install Sohpos VPN/Open VPN on GCE ubuntu

I am new to using Linux, and am trying to install the Sophos SSL VPN Client/Open VPN on a Google Compute Engine (GCE) running ubuntu-1604-xenial-v20210224. The instructions I have seen all refer to ...
user avatar
0 votes
0 answers
19 views

Replacing Google Cloud Print in Raspbian based order printer

For the past couple of years, I have been running an automated order printer for packing orders from my webshop. Until now, I have made the webserver create a PDF of the order contents, and sent that ...
user avatar
0 votes
1 answer
84 views

write a carriage return to a file in cloud shell

I have a file which is havig '\n' at the end of each record of a given file. I would like to have '\r\n' at the end of each record. I tried below but upon checking on notepad++.. see same line ...
user avatar
1 vote
0 answers
21 views

How to personalize dotfiles on gcp instances

On gcp (google cloud), the first time a user connects (via ssh) to a vm a new home directory is created and dotfiles are populated from /etc/skel. How can I configure things to get user specific ...
user avatar
0 votes
0 answers
47 views

What's wrong with this background command?

In a Google Cloud Debian VM, I'm running the following command on the Bash shell: python programname.py > output.txt & I want it to pass its stdout to output.txt and run the program in the ...
user avatar
2 votes
1 answer
173 views

bcache fails to attach local ssd as caching device in google cloud

I'm trying to setup bcache in an instance in google cloud using a raid of local SSDs as caching device but everything fails in the attach phase of the process. For testing purposes I created a new ...
user avatar
  • 21
2 votes
0 answers
506 views

GCP wget (and curl) fails to download file Error 403

I started using GCP (Google Cloud Platform) recently. I created an Ubuntu VM in Google Cloud Engine, and wanted to download some files from a website via wget. I am able to download it using a normal ...
user avatar
1 vote
0 answers
138 views

Can't change netmask to other than /32 for a Debian virtual machine created on google cloud platform

I have created two virtual machines in google cloud platform both are on the same VPC 10.164.0.0/20. One machine is configure with static IP 10.164.0.2, and the other machine is configure with static ...
user avatar
1 vote
1 answer
281 views

Fastest way to download data from GCS bucket

We have millions of files in some GCS bucket and I normally use GSUTIL to download some files based on some pattern to my local. gsutil -m cp -R "gs://test-bucket-data-ingest/cm_data/AAA_AN/CM/*/...
user avatar
1 vote
1 answer
757 views

coverting timestamp to epoch seconds and vice versa in PostgresSQL

I can run below queries to get the epoch seconds from date and can covert back them to given date in Google bigquery. For example: select unix_seconds(timestamp('2020-12-04 00:00:00')), unix_seconds(...
user avatar
1 vote
1 answer
150 views

gcloud setting up zsh alias

I was trying to set up some alias command and function for gcloud. I have written below function and running it in zsh in mac. It runs fine when I pass c and i as individual arguments but not when I ...
user avatar
  • 267
0 votes
1 answer
154 views

Shell causing error in referencing variable in query

I am executing a query in shell to access Google Bigquery table. Cannot figure out what is causing the error. #!/bin/bash file_path='/home/vikrant_singh_rana/test_bq_file.csv' { read while ...
user avatar
1 vote
1 answer
964 views

Using multiple alias in a single command

I'm facing problem in using multiple alias in a single line on Mac bash Terminal. I have setup below alias in my .bash_profile file alias gc=gcloud alias cmp=compute alias ins=instances alias pdev=&...
user avatar
  • 267
0 votes
0 answers
1k views

gcloud command not working with python virtual environment

I am having a Linux server with Centos7 as operating system. I have installed gcloud and it's working fine. [xyz@innolx20122 ~]$ gcloud version Google Cloud SDK 308.0.0 alpha 2020.08.28 beta 2020.08....
user avatar
1 vote
1 answer
385 views

Why can I get man pages for section 1, but not for section 2 and section 3 on a google cloud VM?

I'm running Centos7 on a google cloud VM. I've installed man but can get man pages only for section 1 of the manual. Even as root, I can only get man pages for section 1. For example with the section ...
user avatar
1 vote
0 answers
23 views

How to use eCryptfs under Google Cloud Shell?

I am trying to use ecryptfs under Google Cloud Shell. Google Cloud Shell is a virtual machine running Debian GNU/Linux 9. I installed ecryptfs-utils package using command: sudo apt install ecryptfs-...
user avatar
  • 478
1 vote
1 answer
192 views

ssh config to start session with google cloud compute instance using gcloud cli command

I would like to use my ssh config to use a google cloud cli (gcloud) to connect to google compute instances. (This is a follow-on to another question I asked, that had a working solution, but didn't ...
user avatar
1 vote
2 answers
872 views

ssh config to start session with google cloud compute instance

I would like to use my ssh config to use a google cloud compute instance as a jumpbox to connect to another box. However, I am having problems getting a config that will allow me to even connect to ...
user avatar
0 votes
1 answer
1k views

How to force a custom disk encryption on a google cloud compute instance (gcloud)?

Google cloud services (computing instance) offer encryption by default for disk storage, the customer can provide its own key with the feature customer supplied encryption (detailed here also). How ...
user avatar
  • 12.7k
0 votes
0 answers
148 views

Can't install helm on Debian (Pop_OS) because of a 404. How can I get around that?

I am running this script from the cloud.google.com doc: # Create environment variable for correct distribution export CLOUD_SDK_REPO="cloud-sdk-$(lsb_release -c -s)" # Add the Cloud SDK distribution ...
user avatar
  • 456
1 vote
3 answers
494 views

SFTP server with third party user management system?

I understand how to set up SFTP servers on Linux and create users and their passwords manually. So basically, the users get authenticated as normal Linux users get authenticated through /etc/passwd. ...
user avatar
0 votes
1 answer
607 views

Unable to open VS Code on Ubuntu VM instance on Google Cloud

I am facing a problem when trying to open VS Code on my Virtual machine in Google cloud using VNC viewer.  It's Real VNC, and I checked that vscode is not running in multiple VNC sessions. The VM is ...
user avatar
  • 1
1 vote
0 answers
242 views

Problem when piping stdin to tar

I need to write data (multiple files and directories) from a Google cloud storage bucket onto a Tar archive on my local disk. The directories are multiple TB, so I do not want to create the Tar ...
user avatar
1 vote
1 answer
668 views

How to install Google Cloud completion in NixOS with Oh-My-Zsh?

Oh-my-zsh has a plugin option (plugins = (gcloud, ...)) which allows installing gcloud completions. When I add "gcloud" to plugins, I expect that the completion will be sourced during shell ...
user avatar
7 votes
3 answers
3k views

With Ansible, is it possible to connect connect to hosts that are behind Cloud IAP (Identity-Aware Proxy) in GCP?

Cloud IAP is a sort of proxy for Google Cloud Platform that lets you connect to compute instances that don't have public IP addresses, without a VPN. You stand up an instance and then you can use the ...
user avatar
  • 111
0 votes
1 answer
60 views

write mistake bash_profile

I am using GCE, I want to install Scala on Google Cloud Shell, so I first install the brew, however when I added the brew path to bash_profile, I did a mistake. First of All, I downloaded the brew. ...
user avatar
  • 1
0 votes
0 answers
39 views

How to verify my google cloud storage downloads of csv files are successful?

I have created some shell script to put the data into google cloud storage from some source and download that into my local. I am able to do it and the job is also running fine, but my question is, is ...
user avatar
  • 141
2 votes
0 answers
55 views

Strange difference of disk size

I have a Google Cloud Instance: When i check the disk space with two different command it show: df -H Filesystem Size Used Avail Use% Mounted on /dev/sda2 11G 3.1G 7.5G 30% / ...
user avatar
1 vote
0 answers
720 views

Access permissions for google-compute-engine script

I would like to run a python script on compute engine, which uses a Linux-based operating system ("debian-9-stretch-v20180307"). I am using a bash boot script with code as follows: #! /bin/bash ...
user avatar
  • 111
1 vote
1 answer
98 views

Process ownership automatically changes to init process on GCP Ubuntu 18.04LTS

We recently moved our development infrastructure from our own old machines running Ubuntu 12.04 to Google Cloud instances running Ubuntu 18.04. Developers usually start some screens and run django ...
user avatar
0 votes
0 answers
526 views

Google Compute Engine: ssh with publickey stops working after logout

From google compute engine instance, connected via ssh with web terminal [gcp-instance] $ ssh-copy-id user@server /usr/bin/ssh-copy-id: INFO: attempting to log in with the new key(s), to ...
user avatar
  • 113
4 votes
1 answer
17k views

Debian 9 stretch-backports signature couldn't be verified [duplicate]

I'm trying to install certbot on my Debian 9 server on Google compute engine VM. Here's what I have done so far: To add backports repository, I have edit the sources.list as: sudo nano /etc/apt/...
user avatar
1 vote
1 answer
745 views

Automating postfix installation

I have been trying to automatically install postfix in a non-interactive way via startup-script on machine boot up. After a bit of research I found out some suggestion that I could try to install it ...
user avatar
4 votes
1 answer
6k views

Connect to VM through SSH (Google Colab and PuTTY)

I want to connect to a Google Colab computer via SSH because it has really shit text editing abilities, and it likes to hide the characters I type in the interactive shell. This is code I have on a ...
user avatar
3 votes
2 answers
2k views

Is it important to fix warnings about martian packets in the kernel ring buffer?

These are the outputs I see when I run dmesg [1373335.656608] device eth0 entered promiscuous mode [1373364.891962] device eth1 entered promiscuous mode [1374537.599978] IPv4: martian source 10.5.0.2 ...
user avatar
  • 823
0 votes
1 answer
212 views

vsftp user upload files into moved folder outside of allowed folder

Google VM, centos 7, vsftpd server. I have ftpuser, homedir /var/www/html cat /etc/passwd | grep ftpuser ftpuser:x:1001:48::/var/www/html:/bin/bash from root user I have moved folder /var/www/html ...
user avatar
0 votes
1 answer
93 views

Cloud Shell idle cpu usage seems relatively high (3-6%) - where is this usage coming from?

top - 12:10:09 up 2:18, 6 users, load average: 0.03, 0.03, 0.00 Tasks: 35 total, 1 running, 34 sleeping, 0 stopped, 0 zombie %Cpu(s): 2.1 us, 1.4 sy, 0.0 ni, 96.5 id, 0.0 wa, 0.0 hi, ...
user avatar
  • 44.3k
2 votes
0 answers
680 views

Headless OpenGL rendering on Google Compute

I created a GPU instance on Google Compute engine with NVIDIA Tesla K80 attached. I have installed GPU drivers and CUDA based on this guide. nvidia-smi check - ok. nvcc -V check - ok Now I am ...
user avatar
4 votes
2 answers
5k views

GCP: Debian stuck at setting up dbus

I have been trying to install GUI, i.e. gnome and lxde, into Debian 9 stretch in google cloud computing instance. I have even increased the cpu, ram, harddisk size. However, the installation is always ...
user avatar
0 votes
0 answers
276 views

SELinux setsebool command fails on Google compute engine

I am trying to setup my website (LAMP stack, CentOS 6.9) on Google compute engine. I use PHPMailer to send mails (Registration, Singup, Login, etc.) I have setup smtp & all that good stuff in G-...
user avatar
  • 101
0 votes
1 answer
1k views

Openvpn issues with routing and config pushing

I have recently installed an openvpn server on GCP, in a docker container, from https://github.com/kylemanna/docker-openvpn. The docker-host has packet forwarding enabled. Now I am struggling with ...
user avatar
  • 1,333