>PROBLEM
iptables: No chain/target/match by that name.
>SOLUTION
This post shows two of them.
Scenario:
After performing an upgrade using:
apt update
apt upgrade
nginx returns installing issues and fails to start, returning an error message like this:
Aug 04 13:28:47 myserver.com systemd[1]: Failed to start A high performance web server and a reverse proxy server.
dpkg: error processing package nginx-full (--configure):
installed nginx-full package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of nginx:
nginx depends on nginx-full (<< 1.14.2-2+deb10u4.1~) | nginx-light (<< 1.14.2-2+deb10u4.1~) | nginx-extras (<< 1.14.2-2+deb10u4.1~); however:
Package nginx-full is not configured yet.
Package nginx-light is not installed.
Package nginx-extras is not installed.
Eclipse returns on face-config.xml file the following message:
schema_reference.4: Failed to read schema document 'platform:/plugin/org.eclipse.xsd/cache/www.w3.org/2001/xml.xsd'
Git pull command fails returning error message of corrupted file:
git pull
error: object file .git/objects/dd/4b0b1a777609ba3f787823e566bfc989905319 is empty
fatal: loose object dd4b0b1a777609ba3f787823e566bfc989905319 (stored in .git/objects/dd/4b0b1a777609ba3f787823e566bfc989905319) is corrupt
1.. Copy the corrupted file from another local repository.
If there isn't another, you may clone one.
2. Issue the pull command again.
mvn archetype:generate -DarchetypeGroupId=org.codehaus.mojo.archetypes -DarchetypeArtifactId=ejb-javaee7
Returns:
[ERROR] Child module..does not exist @
Check your pom.xml.
Also, check the mirror's configuration in the maven's settings.xml file.
Example:
C:\Users\MYLOGIN\.m2\settings.xml
<mirrors>
<mirror>
<id>client-repo</id>
<mirrorOf>*</mirrorOf>
<url>http://xyz.core.cliente:8099/nexus/content/groups/my-group/</url>
</mirror>
</mirrors>
Comment, or remove the mirror that is not providing connection.
If it is a project mandatory resource, then report.
Windows10
(Same for *nix or apple except the paths)
After adding an implementation to bind using ngModel , for instance:
<p>
<label for="example-ngModel">[(ngModel)]:</label>
<input [(ngModel)]="currentItem.name" id="example-ngModel">
</p>
Return the error message:
error NG8002: Can't bind to 'ngModel' since it isn't a known property of 'input'
@SEE: this issue may also be caused by other factors, check:
angular-ngform-error-ng8002-cant-bind.html
Make sure that the app.module.ts has the following configuration:
import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';
import { FormsModule } from '@angular/forms'; // <--- JavaScript import from Angular
@NgModule({
declarations: [
AppComponent,
// ...
],
imports: [
BrowserModule,
FormsModule,
AppRoutingModule
],
providers: [],
bootstrap: [AppComponent]
})
export class AppModule { }
In the app.component.ts (or whatever) file, check the import and make sure the constructor() and ngOnInit() are both declared:
import { Component, OnInit } from '@angular/core'; // minimal
//import { Component, OnInit, Output, Input, EventEmitter } from '@angular/core'; // usual
constructor() { }
ngOnInit(): void {
}
node.js 14.x.x
windows
The code below returns the error message:
This condition will always return 'true' since the types 'string' and 'EventEmitter<string>' have no overlap.ts(2367)
*** BAD
crossOffItem(event: EventEmitter<string>): void {
const ritems = this.items.filter( it => it !== event);
this.items = ritems;
}
TypeScript complains that the types are not explicitly equivalent or comparable.
*** OK
crossOffItem(event: EventEmitter<string>): void {
const ritems = this.items.filter( it => it !== event.toString());
this.items = ritems;
}
crossOffItem(event: EventEmitter<string>): void {
const val = event.toString();
const ritems = this.items.filter( it => it !== val);
this.items = ritems;
}
You need to work with different environments and workspaces for different purposes when working with different programming languages or different contexts.
For each context or environment, you've installed the desired extensions.
Also, it is interesting to keep a backup of the environment to save time.
If you have just one configuration setup and many needs, the VS Code configuration begins growing, eventually getting heavy, slow, and taking too much memory.
Also, the extensions' default shortcuts begin to conflict with each other.
There are at least three approaches:
1. Versioning control using branches, or
2. Separate configuration folders, or
3. Option 1 plus option 2.
The VS Code default folder that holds its configuration setup is under
"C:\Users\YOUR_LOGIN\.vscode" folder.
Create a git repository there.
For each kind of environment desired, create a specific branch.
The master branch would aggregate everything, but in this case, there is no use unless you do want to keep a backup of just one setup.
You may combine the two options above, but better if the branches keep a keyword to avoid losing control.
The best of all is that you never lose your env, never need to reconfigure, and may switch fast the environments preserving then VS Code app from getting messed and slow.
When rebooting the machine, returned blue screen with the following message:
windows system error STATUS_WAIT_3 0x80070003
Another attempt, returned another message:
windows system error STATUS_WAIT_2 0x80070002
Git push fails returning "Updates were rejected because a pushed branch tip is behind its remote counterpart...".
! [rejected] master -> master (non-fast-forward)
error: failed to push some refs to .. SOME DIR PATH
hint: Updates were rejected because a pushed branch tip is behind its remote
hint: counterpart. Check out this branch and integrate the remote changes
hint: (e.g. 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
Following the hint suggested in the output:
git push --help
The --force option solves:
git push --force origin master
Because it was behind the counterpart, it may cause some side effect on log.
When performed the command, everything was fine, no issues, but another client had to push with --force flag too, but no further issues.
>ENV
Windows 10
Git version 2.19.1.windows.1
git: 'credential-cache' is not a git command. See 'git --help'.
Edit .git\config fille and remove:
[credential]
helper = cache
Windows 10
This procedure resets the MariaDB root password when it is not possible to access the database returning:
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
- Stop database:
sudo systemctl stop mariadb
- Test:
sudo systemctl status mariadb
You shall get;
Status: "MariaDB server is down"
To return to console, use Ctrl+C
- This command shall return empty:
sudo pgrep mysqld
- Starting the database using safe mode:
sudo mysqld_safe --skip-grant-tables --skip-networking &
or
sudo mysqld_safe --skip-grant-tables &
"Enter" to return to prompt.
mysql -u root
use mysql;
flush privileges;
update user SET PASSWORD=PASSWORD('secret') WHERE USER='root';
GRANT ALL PRIVILEGES ON root.* TO 'root'@'localhost' WITH GRANT OPTION;
flush privileges;
quit
- kill all mysqld processes
sudo pgrep mysqld
- Kill by the PID numbers returned, for example:
sudo kill -9 1234
sudo kill -9 4567
- Start the database:
sudo systemctl start mariadb
- Access the database again to test the "secret" temporary password and also to change to the definitive password:
mysql -u root -p
pass: secret
use mysql;
flush privileges;
UPDATE mysql.user SET authentication_string = PASSWORD('MY_DEFINITIVE_PASSWORD') WHERE User = 'root' AND Host = 'localhost';
GRANT ALL PRIVILEGES ON root.* TO 'root'@'localhost' WITH GRANT OPTION;
GRANT RELOAD ON *.* TO 'root'@'localhost';
flush privileges;
quit
- Access the database again to test the definitive password:
mysql -u root -p
pass: MY_DEFINITIVE_PASSWORD
***NOTE:
If after switching to the definitive password, the problem comes back denying access, it is because the characters used in the password caused the issue.
Avoid password like this:
Abc1234#-_ (the -_ didn't work during my attempts)
For sure, use a password with just numbers and letters.
To get confidence, repeat the procedure.
If you desire to use special chars, you may try after making sure that you got success at least once, that way you may discover which special char to avoid in your password.
debian 10/9
10.x , 10.3.27-MariaDB
This procedure was executed several times successfully, but you may get some issue with some command shown above.
Below, there are some alternatives, not all of them of course, that you may try if some command fails.
set password for 'root'@'localhost' = password('secret');
- or
ALTER USER 'root'@'localhost' IDENTIFIED BY 'secret';
www.digitalocean.com/community/tutorials/how-to-reset-your-mysql-or-mariadb-root-password
robbinespu.github.io/eng/2018/03/29/Reset_mariadb_root_password.html
alsdias.blogspot.com/2020/12/mariadb-error-1045-28000-access-denied.html
@SYSREF:
y;reset root password<memo<mariadb;.
The "ZTE MF253L LTE Wireless" Wi-Fi modem/router sometimes fails to accept Wi-Fi connections and comes with issues when using RJ-45.
A very odd defect that occurred after some years of usage.
ZTE MF253L has not a wide signal range but works well.
Instead of buying another modem/router, I decided to use a tp-link Wireless N 450Mbps router, model TL-WR940N, connected to the ZTE's internet output, using the RJ-45 cable.
The TL-WR940N model has a good signal range.
Now, I connect the notebooks direct to the tp-link router, instead of to the ZTE's, solving the connection issues. No more problems, at all.
Sometimes, when the ZTE's direct connection is not failing, it is possible to use it without the tp-link, but it is not an advantage at all, but remains as an alternative in case of a casual tp-link failure.
When the provider's connection fails, the Window's wi-fi connections keeps the tp-link router active waiting and as soon as the connection is on again and nothing is changed on the notebooks connected to the tp-link.
This saves time when the failures are short.
If not, you may connect to the tp-link another modem/router using another number, a second option when you have it, without changing clients' configurations. If you have many machines, it helps a lot.
For some reason, sometimes Windows fails to reconnect the Wi-Fi, forcing to do a reboot.
This workaround also avoids this reboot.
! [remote rejected] master -> master (unable to migrate objects to permanent storage)
error: failed to push some refs to 'ssh://REPOSITORY_PATH_HERE'
You want to copy a code snippet and paste into an HTML page that has its own CSS selectors.
For example, you are working on Eclipse, VSCode, Atom, Sublime, etc. and you wish to copy and paste the snippet below to your post in HTML.
server { server_name marketing.example.com marketing.example.org marketing. example.net; rewrite ^ http://www.example.com/marketing/application.do permanent; } server { server_name communication.example.com communication.example.org communication.example.net; rewrite ^ http://www.example.com/comms/index.cgi permanent; } server { server_name www.example.org www.example.net; rewrite ^ http://www.example.com$request_uri permanent; }
Returns:
Job for nginx.service failed because the control process exited with error code. See "systemctl status nginx.service" and "journalctl -xe" for details. invoke-rc.d: initscript nginx, action "start" failed. ● nginx.service - A high performance web server and a reverse proxy server Loaded: loaded (/lib/systemd/system/nginx.service; enabled; vendor preset: enabled) Active: failed (Result: exit-code) since Sat 2020-09-26 22:49:18 UTC; 7ms ago Docs: man:nginx(8) Process: 21405 ExecStart=/usr/sbin/nginx -g daemon on; master_process on; (code=exited, status=1/FAILURE) Process: 21404 ExecStartPre=/usr/sbin/nginx -t -q -g daemon on; master_process on; (code=exited, status=0/SUCCESS) Sep 26 22:49:17 mind4y.com nginx[21405]: nginx: [emerg] listen() to [::]:80, backlog 511 failed (98: Address already in use) Sep 26 22:49:17 mind4y.com nginx[21405]: nginx: [emerg] listen() to 0.0.0.0:80, backlog 511 failed (98: Address already in use) Sep 26 22:49:17 mind4y.com nginx[21405]: nginx: [emerg] listen() to [::]:80, backlog 511 failed (98: Address already in use) Sep 26 22:49:18 mind4y.com nginx[21405]: nginx: [emerg] listen() to 0.0.0.0:80, backlog 511 failed (98: Address already in use) Sep 26 22:49:18 mind4y.com nginx[21405]: nginx: [emerg] listen() to [::]:80, backlog 511 failed (98: Address already in use) Sep 26 22:49:18 mind4y.com nginx[21405]: nginx: [emerg] still could not bind() Sep 26 22:49:18 mind4y.com systemd[1]: nginx.service: Control process exited, code=exited status=1 Sep 26 22:49:18 mind4y.com systemd[1]: Failed to start A high performance web server and a reverse proxy server. Sep 26 22:49:18 mind4y.com systemd[1]: nginx.service: Unit entered failed state. Sep 26 22:49:18 mind4y.com systemd[1]: nginx.service: Failed with result 'exit-code'. dpkg: error processing package nginx-full (--configure): subprocess installed post-installation script returned error exit status 1 dpkg: dependency problems prevent configuration of nginx: nginx depends on nginx-full (<< 1.10.3-1+deb9u4.1~) | nginx-light (<< 1.10.3-1+deb9u4.1~) | nginx-extras (<< 1.10.3-1+deb9u4.1~); however: Package nginx-full is not configured yet. Package nginx-light is not installed. Package nginx-extras is not installed. nginx depends on nginx-full (>= 1.10.3-1+deb9u4) | nginx-light (>= 1.10.3-1+deb9u4) | nginx-extras (>= 1.10.3-1+deb9u4); however: Package nginx-full is not configured yet. Package nginx-light is not installed. Package nginx-extras is not installed. dpkg: error processing package nginx (--configure): dependency problems - leaving unconfigured Errors were encountered while processing: nginx-full nginx E: Sub-process /usr/bin/dpkg returned an error code (1)
nginx[21405]: nginx: [emerg] listen() to 0.0.0.0:80
Switch Nginx or Apache to another port.
In this case, Nginx is switched to port 81.
1. Edit:
/etc/nginx/sites-enabled/default
Switch from:
server {
listen 80 default_server;
listen [::]:80 default_server;
To:
server {
listen 81 default_server;
listen [::]:81 default_server;
VMWare has ping to host but host has not ping to the VMWare running Debian.
For instance, on console, you type python and opens instead Windows Store panel or another program.
- Go to:
C:\Users\your_user_login_here\AppData\Local\Microsoft\WindowsApps
- Possibly, there is an equivalent command shadowing the one you really wish.
Delete it or rename it.
That's it.
>PROBLEM Using Eclipse, you try to run a simple logging test using "org.slf4j.Logger" like the sample below: package Test; im...