Skip to content

Conversation

@sam-github
Copy link
Contributor

No description provided.

@sam-github
Copy link
Contributor Author

@mhdawson @rvagg This is related to #2005 (comment)

I'd like to link this to some issue that describes why we are doing this but haven't found one.

Copy link
Member

@mhdawson mhdawson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@sam-github sam-github changed the title ansible: test-joyent-smartos*-x64-[34] WIP ansible: test-joyent-smartos*-x64-[34] Oct 28, 2019
@sam-github
Copy link
Contributor Author

TASK [baselayout : ccache : prepare for compilation] **********************************
fatal: [test-joyent-smartos15-x64-3]: FAILED! => {"changed": true, "cmd": "./configure -q", "delta": "0:00:02.227336", "end": "2019-10-28 17:43:41.943024", "msg": "non-zero r
eturn code", "rc": 1, "start": "2019-10-28 17:43:39.715688", "stderr": "configure: error: in `/tmp/ccache-3.6':\nconfigure: error: cannot run C compiled programs.\nIf you mea
nt to cross compile, use `--host'.\nSee `config.log' for more details", "stderr_lines": ["configure: error: in `/tmp/ccache-3.6':", "configure: error: cannot run C compiled p
rograms.", "If you meant to cross compile, use `--host'.", "See `config.log' for more details"], "stdout": "", "stdout_lines": []}                                           
fatal: [test-joyent-smartos15-x64-4]: FAILED! => {"changed": true, "cmd": "./configure -q", "delta": "0:00:02.315163", "end": "2019-10-28 17:43:42.105257", "msg": "non-zero r
eturn code", "rc": 1, "start": "2019-10-28 17:43:39.790094", "stderr": "configure: error: in `/tmp/ccache-3.6':\nconfigure: error: cannot run C compiled programs.\nIf you mea
nt to cross compile, use `--host'.\nSee `config.log' for more details", "stderr_lines": ["configure: error: in `/tmp/ccache-3.6':", "configure: error: cannot run C compiled p
rograms.", "If you meant to cross compile, use `--host'.", "See `config.log' for more details"], "stdout": "", "stdout_lines": []}                                           
changed: [test-joyent-smartos17-x64-4]
changed: [test-joyent-smartos17-x64-3]

TASK [baselayout : ccache : compile] **************************************************
fatal: [test-joyent-smartos17-x64-4]: FAILED! => {"changed": false, "cmd": "/opt/local/bin/gmake", "msg": "gmake: *** No targets specified and no makefile found.  Stop.", "rc
": 2, "stderr": "gmake: *** No targets specified and no makefile found.  Stop.\n", "stderr_lines": ["gmake: *** No targets specified and no makefile found.  Stop."], "stdout"
: "", "stdout_lines": []}
fatal: [test-joyent-smartos17-x64-3]: FAILED! => {"changed": false, "cmd": "/opt/local/bin/gmake", "msg": "gmake: *** No targets specified and no makefile found.  Stop.", "rc
": 2, "stderr": "gmake: *** No targets specified and no makefile found.  Stop.\n", "stderr_lines": ["gmake: *** No targets specified and no makefile found.  Stop."], "stdout"
: "", "stdout_lines": []}

Looking into this.

@sam-github
Copy link
Contributor Author

sam-github commented Oct 28, 2019


configure:2976: gcc -o conftest    conftest.c  >&5
configure:2980: $? = 0
configure:3002: result: 
configure:3024: checking whether we are cross compiling
configure:3032: gcc -o conftest    conftest.c  >&5
In file included from /usr/include/stdio.h:37:0,
                 from conftest.c:17:
/usr/include/sys/feature_tests.h:400:2: error: #error "Compiler or options invalid; UNIX 03 and POSIX.1-2001 applications       require the use of c99"
 #error "Compiler or options invalid; UNIX 03 and POSIX.1-2001 applications \
  ^

@sam-github
Copy link
Contributor Author

@nodejs/platform-smartos I'll bang away at above, but would appreciate any advice from people who have used SmartOS for more than 5 minutes (which is me).

@sam-github
Copy link
Contributor Author

This gets further:

% ./configure CPPFLAGS=-std=c99
...
checking whether C compiler supports -Wno-implicit-fallthrough... yes
configure: creating ./config.status
./config.status: line 678: syntax error at line 716: `<<' unmatched
cat: config.h: No such file or directory
configure: now build ccache by running make
[root@f73879c5-f01c-ed18-a8bb-9eb251eb2e96 /tmp/ccache-3.6]# make
make: *** No targets specified and no makefile found.  Stop.

@sam-github
Copy link
Contributor Author

Turns out ccache can only be compiled as C99, and that its configure system is not compatible with solaris' /bin/sh. See a62810f

@sam-github
Copy link
Contributor Author

sam-github commented Oct 28, 2019

Next error:

fatal: [test-joyent-smartos15-x64-3]: FAILED! => {"msg": "The conditional check 'os = "ubuntu1404" and arch != "ppc64"' failed. The error was: template error while templating string: expected token 'end of statement block', got '='. String: {% if os = "ubuntu1404" and arch != "ppc64" %} True {% else %} False {% endif %}\n\nThe error appears to be in '/home/sam/w/core/build/ansible/roles/java-base/tasks/main.yml': line 7, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n\n- name: install add-apt-repostory\n ^ here\n"}

@sam-github
Copy link
Contributor Author

I think the conditionals were malformed, not sure how that snuck in, see 7f99d3f

@sam-github
Copy link
Contributor Author

With that last change, jenkins/worker/create runs to completetion.

@sam-github
Copy link
Contributor Author

Rebased onto master after #2010 landed.

@sam-github
Copy link
Contributor Author

I cloned the existing -2 nodes into the new -3/-4 nodes, updated the secrets, re-ansibled, now they need firewall rules setup by @mhdawson (or someone else in @nodejs/build-infra ).

@mhdawson
Copy link
Member

Firewall rules setup

@sam-github
Copy link
Contributor Author

I made the configure changes conditional on the OS, but will wait to confirm they work until the test job is quiet before re-ansibling them: https://ci.nodejs.org/job/node-test-commit-smartos

@rvagg
Copy link
Member

rvagg commented Oct 28, 2019

Again, this is the hard way of doing it, I'm not objecting, just pointing it out. If you add additional machines then you have to make new entries here, secrets, ci firewall and jenkins UI. Then you'll have to do the inverse of all 4 of those things when you remove the old machines. If you just replace old machines you just have to update the ip address here and in ci firewall. You get to reuse secrets and the Jenkins entry. If you're worried about downtime because there's multiple people and potentially multiple days, these are just test machines so you could disable the entire test-node-commit-smartos and they'll be mostly unused.

Edit: Michael mentions some of the reasoning here: #2003 (comment), I'm not trying to get in the way here, just pointing out how I do it to minimise effort and duplication. Take it as you will. Thanks for taking on this work.

@sam-github
Copy link
Contributor Author

I don't have strong feelings, and the extra work is already done.

As a note - the amount of time spent on copying machine defs was a 10th of the time spent getting ansilble to run without errors.

I removed the silencing of deprecation warnings, since some people find them useful.


- name: "ccache : prepare for compilation - smartos"
when: os|startswith("smartos")
shell: bash ./configure CPPFLAGS=-std=c99
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I remember this but may have resorted to an older version of ccache to get around it. Good change, thanks for figuring it out!

@sam-github
Copy link
Contributor Author

builds green on the new smartos hosts:

@sam-github sam-github changed the title WIP ansible: test-joyent-smartos*-x64-[34] ansible: test-joyent-smartos*-x64-[34] Oct 30, 2019
@sam-github sam-github merged commit 5e9585a into nodejs:master Oct 30, 2019
@sam-github sam-github deleted the add-smartos-3_-4 branch October 30, 2019 16:48
sam-github added a commit that referenced this pull request Nov 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants